Commit 6fd8c28d authored by Max Kellermann's avatar Max Kellermann

playlist: free memory with g_free()

Use g_free() consistently with g_malloc(). Don't clear the pointers after freeing them.
parent b14e48f9
......@@ -195,16 +195,11 @@ void finishPlaylist(void)
playlist.length = 0;
free(playlist.songs);
playlist.songs = NULL;
free(playlist.songMod);
playlist.songMod = NULL;
free(playlist.order);
playlist.order = NULL;
free(playlist.idToPosition);
playlist.idToPosition = NULL;
free(playlist.positionToId);
playlist.positionToId = NULL;
g_free(playlist.songs);
g_free(playlist.songMod);
g_free(playlist.order);
g_free(playlist.idToPosition);
g_free(playlist.positionToId);
g_rand_free(g_rand);
g_rand = NULL;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment