summaryrefslogtreecommitdiff
path: root/plugins/lastfm
diff options
context:
space:
mode:
authorGravatar waker <wakeroid@gmail.com>2009-08-28 21:58:43 +0200
committerGravatar waker <wakeroid@gmail.com>2009-08-28 21:58:43 +0200
commita1146a1ce3983d05fed52d7a763e79856dcc6f9b (patch)
treecaa28d897f1c183b03efc5f577c53c02bb162616 /plugins/lastfm
parent4c41a6c6c9accea5854755bbb0f1a3476d31f8b2 (diff)
changed pl_find_meta behavior to return NULL for not-found items
Diffstat (limited to 'plugins/lastfm')
-rw-r--r--plugins/lastfm/lastfm.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/plugins/lastfm/lastfm.c b/plugins/lastfm/lastfm.c
index 190fa1a0..d0f53d48 100644
--- a/plugins/lastfm/lastfm.c
+++ b/plugins/lastfm/lastfm.c
@@ -227,24 +227,24 @@ fail:
static int
lfm_fetch_song_info (DB_playItem_t *song, const char **a, const char **t, const char **b, float *l, const char **n, const char **m) {
*a = deadbeef->pl_find_meta (song, "artist");
- if (!strcmp (*a, "?")) {
+ if (!*a) {
return -1;
}
*t = deadbeef->pl_find_meta (song, "title");
- if (!strcmp (*t, "?")) {
+ if (!*t) {
return -1;
}
*b = deadbeef->pl_find_meta (song, "album");
- if (!strcmp (*b, "?")) {
+ if (!*b) {
return -1;
}
*l = song->duration;
*n = deadbeef->pl_find_meta (song, "track");
- if (!strcmp (*n, "?")) {
+ if (!*n) {
*n = "";
}
*m = deadbeef->pl_find_meta (song, "mbid");
- if (!strcmp (*m, "?")) {
+ if (!*m) {
*m = "";
}
return 0;