X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~mdw/git/disorder/blobdiff_plain/6982880f199dda54b194408f5b4fb3c42c734e79..e7b9569145b3469f9487ac31155410cd2d982a3c:/disobedience/queue.c diff --git a/disobedience/queue.c b/disobedience/queue.c index fe9e707..d69b34d 100644 --- a/disobedience/queue.c +++ b/disobedience/queue.c @@ -32,10 +32,10 @@ struct queue_entry *playing_track; time_t last_playing; static void queue_completed(void *v, - const char *error, + const char *err, struct queue_entry *q); static void playing_completed(void *v, - const char *error, + const char *err, struct queue_entry *q); /** @brief Called when either the actual queue or the playing track change */ @@ -75,10 +75,10 @@ static void queue_playing_changed(void) { /** @brief Update the queue itself */ static void queue_completed(void attribute((unused)) *v, - const char *error, + const char *err, struct queue_entry *q) { - if(error) { - popup_protocol_error(0, error); + if(err) { + popup_protocol_error(0, err); return; } actual_queue = q; @@ -87,10 +87,10 @@ static void queue_completed(void attribute((unused)) *v, /** @brief Update the playing track */ static void playing_completed(void attribute((unused)) *v, - const char *error, + const char *err, struct queue_entry *q) { - if(error) { - popup_protocol_error(0, error); + if(err) { + popup_protocol_error(0, err); return; } actual_playing_track = q; @@ -198,9 +198,9 @@ struct queuelike ql_queue = { static int queue_drag_target = -1; static void queue_move_completed(void attribute((unused)) *v, - const char *error) { - if(error) { - popup_protocol_error(0, error); + const char *err) { + if(err) { + popup_protocol_error(0, err); return; } /* The log should tell us the queue changed so we do no more here */ @@ -345,6 +345,8 @@ int queued(const char *track) { struct queue_entry *q; D(("queued %s", track)); + /* Queue will contain resolved name */ + track = namepart_resolve(track); for(q = ql_queue.q; q; q = q->next) if(!strcmp(q->track, track)) return 1;