protocol/Result: move command_list_num to class Response

This commit is contained in:
Max Kellermann
2015-08-14 19:00:02 +02:00
parent c8d0f947d2
commit d053797340
6 changed files with 12 additions and 10 deletions

View File

@@ -363,11 +363,9 @@ command_checked_lookup(Response &r, unsigned permission,
CommandResult
command_process(Client &client, unsigned num, char *line)
{
Response r(client);
Response r(client, num);
Error error;
command_list_num = num;
/* get the command name (first word on the line) */
/* we have to set current_command because Response::Error()
expects it to be set */
@@ -427,7 +425,6 @@ command_process(Client &client, unsigned num, char *line)
: CommandResult::ERROR;
current_command = nullptr;
command_list_num = 0;
return ret;
}