Commit 05f66e04 authored by Max Kellermann's avatar Max Kellermann

update: send proper response to the client

Due to a merge error, I broke the function handleUpdate(). It did not do anything for the global update, and it did not send a proper response to the client. This patch fixes both bugs.
parent 9a5b5998
......@@ -853,13 +853,16 @@ static int handleUpdate(struct client *client,
List *pathList = makeList(NULL, 1);
insertInList(pathList, argv[1], NULL);
ret = updateInit(pathList);
if (ret == -1)
command_error(client, ACK_ERROR_UPDATE_ALREADY,
"already updating");
return ret;
} else {
ret = updateInit(NULL);
}
return ret;
if (ret == -1)
command_error(client, ACK_ERROR_UPDATE_ALREADY,
"already updating");
client_printf(client, "updating_db: %i\n", ret);
return 0;
}
static int handleNext(mpd_unused struct client *client,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment