diff --git a/apps/playlist.c b/apps/playlist.c index 23d3355708..f1edfe7323 100644 --- a/apps/playlist.c +++ b/apps/playlist.c @@ -367,6 +367,9 @@ static int convert_m3u_name(char* buf, int buf_len, int buf_max, char* temp) */ static void create_control_unlocked(struct playlist_info* playlist) { + if (playlist == ¤t_playlist && file_exists(PLAYLIST_CONTROL_FILE)) + rename(PLAYLIST_CONTROL_FILE, PLAYLIST_CONTROL_FILE".old"); + playlist->control_fd = open(playlist->control_filename, O_CREAT|O_RDWR|O_TRUNC, 0666);