diff options
Diffstat (limited to 'src/command.c')
-rw-r--r-- | src/command.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/command.c b/src/command.c index 165e21c96..c48ea845d 100644 --- a/src/command.c +++ b/src/command.c @@ -454,6 +454,7 @@ handle_status(struct client *client, { const char *state = NULL; int updateJobId; + char *error; int song; switch (getPlayerState()) { @@ -515,10 +516,12 @@ handle_status(struct client *client, updateJobId); } - if (getPlayerError() != PLAYER_ERROR_NOERROR) { + error = getPlayerErrorStr(); + if (error != NULL) { client_printf(client, COMMAND_STATUS_ERROR ": %s\n", - getPlayerErrorStr()); + error); + g_free(error); } song = playlist_get_next_song(&g_playlist); |