[empathy/gnome-2-26] Fix memleak in empathy_tp_file_accept. Free content of priv->filename before



commit 257d13551ebec90bea3d3054ed0d4e6f50ffd93b
Author: Lars-Peter Clausen <lars metafoo de>
Date:   Sat Apr 18 02:30:21 2009 +0200

    Fix memleak in empathy_tp_file_accept. Free content of priv->filename before
    overwriting it.
---
 libempathy/empathy-tp-file.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/libempathy/empathy-tp-file.c b/libempathy/empathy-tp-file.c
index 2b65700..1f6bedf 100644
--- a/libempathy/empathy-tp-file.c
+++ b/libempathy/empathy-tp-file.c
@@ -814,6 +814,7 @@ empathy_tp_file_accept (EmpathyTpFile *tp_file,
   if (error && *error)
     return;
 
+  g_free (tp_file->priv->filename);
   tp_file->priv->filename = g_file_get_basename (gfile);
   g_object_notify (G_OBJECT (tp_file), "filename");
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]