[goobox] fixed possible memory leak



commit b180575ebf55f79531156c6ef9ed7fc6fd0c40f9
Author: Paolo Bacchilega <paobac src gnome org>
Date:   Sun Dec 30 12:53:54 2018 +0100

    fixed possible memory leak

 src/goo-window.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
---
diff --git a/src/goo-window.c b/src/goo-window.c
index fc8852b..07e8d71 100644
--- a/src/goo-window.c
+++ b/src/goo-window.c
@@ -1138,7 +1138,7 @@ static gboolean
 notify_current_state_cb (gpointer user_data)
 {
        GooWindow      *window = user_data;
-       GString        *info = g_string_new ("");
+       GString        *info;
        GooPlayerState  state;
 
        if (window->priv->notify_event != 0) {
@@ -1171,6 +1171,8 @@ notify_current_state_cb (gpointer user_data)
                return FALSE;
        }
 
+       info = g_string_new ("");
+
        if (window->priv->album->artist != NULL) {
                char *e_artist = g_markup_escape_text (window->priv->album->artist, -1);
 


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