From cb2af114c5c28430ef4c5e94c90ded897596de23 Mon Sep 17 00:00:00 2001 From: Anna Schumaker Date: Wed, 28 Sep 2016 17:02:42 -0400 Subject: [PATCH] core/playlists/user: Free playlist name during deinit Signed-off-by: Anna Schumaker --- core/playlists/user.c | 1 + include/core/playlists/type.h | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/core/playlists/user.c b/core/playlists/user.c index 0c7a4a9e..cf750018 100644 --- a/core/playlists/user.c +++ b/core/playlists/user.c @@ -26,6 +26,7 @@ static struct db_entry *user_db_alloc(const gchar *name) static void user_db_free(struct db_entry *dbe) { queue_deinit(&USER_PLAYLIST(dbe)->pl_playlist.pl_queue); + g_free(USER_PLAYLIST(dbe)->pl_playlist.pl_name); g_free(USER_PLAYLIST(dbe)); } diff --git a/include/core/playlists/type.h b/include/core/playlists/type.h index e1efb1a2..e2ae5c9b 100644 --- a/include/core/playlists/type.h +++ b/include/core/playlists/type.h @@ -20,7 +20,7 @@ enum playlist_type_t { struct playlist { enum playlist_type_t pl_type; /* This playlist's type. */ - const gchar *pl_name; /* This playlist's name. */ + gchar *pl_name; /* This playlist's name. */ struct queue pl_queue; /* This playlist's queue of tracks. */ };