aboutsummaryrefslogtreecommitdiffstats
path: root/src/update.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2009-02-04 22:33:43 +0100
committerMax Kellermann <max@duempel.org>2009-02-04 22:33:43 +0100
commit5d0c83ba5ec177217b1ccf9832fd749f2c8b58a5 (patch)
tree1ef07f727a41f348d188bb48fbe0c3e2a5ab8660 /src/update.c
parent94685aa9bdc6a7a79990ea677cc1fd880c15dd17 (diff)
downloadmpd-5d0c83ba5ec177217b1ccf9832fd749f2c8b58a5.tar.gz
mpd-5d0c83ba5ec177217b1ccf9832fd749f2c8b58a5.tar.xz
mpd-5d0c83ba5ec177217b1ccf9832fd749f2c8b58a5.zip
update: check whether stickers are enabled
If stickers are not configured at runtime, don't call sticker_song_delete().
Diffstat (limited to '')
-rw-r--r--src/update.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/update.c b/src/update.c
index 276ec5a93..216e40422 100644
--- a/src/update.c
+++ b/src/update.c
@@ -37,6 +37,7 @@
#include "config.h"
#ifdef ENABLE_SQLITE
+#include "sticker.h"
#include "song_sticker.h"
#endif
@@ -722,7 +723,8 @@ static void song_delete_event(void)
#ifdef ENABLE_SQLITE
/* if the song has a sticker, delete it */
- sticker_song_delete(delete);
+ if (sticker_enabled())
+ sticker_song_delete(delete);
#endif
deleteASongFromPlaylist(&g_playlist, delete);