aboutsummaryrefslogtreecommitdiffstats
path: root/src/song_save.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/song_save.c')
-rw-r--r--src/song_save.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/song_save.c b/src/song_save.c
index 1d2724e83..8f4e1614d 100644
--- a/src/song_save.c
+++ b/src/song_save.c
@@ -80,7 +80,8 @@ insertSongIntoList(struct songvec *sv, struct song *newsong)
tag_end_add(newsong->tag);
} else { /* prevent dupes, just update the existing song info */
if (existing->mtime != newsong->mtime) {
- tag_free(existing->tag);
+ if (existing->tag != NULL)
+ tag_free(existing->tag);
if (newsong->tag)
tag_end_add(newsong->tag);
existing->tag = newsong->tag;