summaryrefslogtreecommitdiff
path: root/apps/playlist.c
diff options
context:
space:
mode:
Diffstat (limited to 'apps/playlist.c')
-rw-r--r--apps/playlist.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/playlist.c b/apps/playlist.c
index 2e28fc859d..49c52a9b7e 100644
--- a/apps/playlist.c
+++ b/apps/playlist.c
@@ -3707,7 +3707,7 @@ int playlist_save(struct playlist_info* playlist, char *filename,
3707 if (!rename(path, tmp_buf)) 3707 if (!rename(path, tmp_buf))
3708 { 3708 {
3709 fd = open_utf8(tmp_buf, O_RDONLY); 3709 fd = open_utf8(tmp_buf, O_RDONLY);
3710 if (fsamefile(fd, playlist->fd) > 0) 3710 if (fd >= 0 && fsamefile(fd, playlist->fd) > 0)
3711 { 3711 {
3712 /* Replace the current playlist with the new one and update 3712 /* Replace the current playlist with the new one and update
3713 indices */ 3713 indices */