Skip to content

Commit

Permalink
Update xkcp_mon.c
Browse files Browse the repository at this point in the history
  • Loading branch information
liudf0716 authored Apr 21, 2017
1 parent 40e229f commit 66a5a5c
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions xkcp_mon.c
Original file line number Diff line number Diff line change
Expand Up @@ -89,14 +89,14 @@ static void process_user_cmd(struct bufferevent *bev, const char *cmd, void *ctx
int i = 0;
struct user_spy_cmd *spy_cmd;
if (xkcp_server_flag) {
spy_cmd = &server_cmd[i];
spy_cmd = server_cmd;
} else {
spy_cmd = &client_cmd[i];
spy_cmd = client_cmd;
}

for(; spy_cmd->command != NULL; i++) {
if (strcmp(cmd, spy_cmd->command) == 0)
spy_cmd->cmd_process(bev, ctx);
for(; spy_cmd[i]->command != NULL; i++) {
if (strcmp(cmd, spy_cmd[i]->command) == 0)
spy_cmd[i]->cmd_process(bev, ctx);
}

}
Expand Down

0 comments on commit 66a5a5c

Please sign in to comment.