From: Andre Noll Date: Wed, 31 Oct 2007 00:17:47 +0000 (+0100) Subject: command.c: Fix get_cmd_pointer. X-Git-Tag: v0.3.0~165 X-Git-Url: http://git.tue.mpg.de/?a=commitdiff_plain;h=a7b64b9b52dae1ab49f850376d1d1ce3b2a15946;p=paraslash.git command.c: Fix get_cmd_pointer. The old code did not set the handler for afs commands at all. Bad. --- diff --git a/command.c b/command.c index e294e87c..3a58300e 100644 --- a/command.c +++ b/command.c @@ -376,13 +376,16 @@ static struct server_command *get_cmd_ptr(const char *name, char **handler) for (cmd = server_cmds; cmd->name; cmd++) if (!strcmp(cmd->name, name)) { if (handler) - *handler = para_strdup("para_server"); /* server commands */ + *handler = para_strdup("server"); /* server commands */ return cmd; } /* not found, look for commands supported by afs */ for (cmd = afs_cmds; cmd->name; cmd++) - if (!strcmp(cmd->name, name)) + if (!strcmp(cmd->name, name)) { + if (handler) + *handler = para_strdup("afs"); return cmd; + } return NULL; }