Code

screen_song: free mpd_stats object
authorMax Kellermann <max@duempel.org>
Fri, 14 Aug 2009 21:50:25 +0000 (23:50 +0200)
committerMax Kellermann <max@duempel.org>
Fri, 14 Aug 2009 21:50:25 +0000 (23:50 +0200)
Fix a memory leak.

src/screen_song.c

index 87a78915cb220f7d33b9a1ba0078c77b389437c7..6f1c8b8a075455799a83cdd418b0462d8f1a741a 100644 (file)
@@ -284,6 +284,8 @@ screen_song_add_stats(const mpdclient_t *c)
                g_date_strftime(buf, sizeof(buf), "%x", date);
                screen_song_append(labels[DBUPTIME], buf, max_label_width);
                g_date_free(date);
+
+               mpd_freeStats(mpd_stats);
        }
 }