aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2008-09-15 13:27:33 +0200
committerMax Kellermann <max@duempel.org>2008-09-15 13:27:33 +0200
commit3da600fbb0c33ec5cfb76e5341cf21c160592202 (patch)
tree1bce6e91b790fce761352a6100445978d6ad9717 /src
parent3ef31f6e0c13aa7b2ebd1fcacd7e1aa3ac560ba5 (diff)
downloadmpd-3da600fbb0c33ec5cfb76e5341cf21c160592202.tar.gz
mpd-3da600fbb0c33ec5cfb76e5341cf21c160592202.tar.xz
mpd-3da600fbb0c33ec5cfb76e5341cf21c160592202.zip
free info entity while iterating
Memory leak: the function mpdclient_playlist_update_changes() did not free the entity which was returned by mpd_getNextInfoEntity(). Add a mpd_freeInfoEntity() call at the end of each iteration.
Diffstat (limited to '')
-rw-r--r--src/mpdclient.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/mpdclient.c b/src/mpdclient.c
index 57b470681..c59741115 100644
--- a/src/mpdclient.c
+++ b/src/mpdclient.c
@@ -753,6 +753,8 @@ mpdclient_playlist_update_changes(mpdclient_t *c)
c->playlist.list = g_list_append(c->playlist.list,
(gpointer)mpd_songDup(song));
}
+
+ mpd_freeInfoEntity(entity);
}
/* remove trailing songs */