summaryrefslogtreecommitdiff
path: root/src/base
diff options
context:
space:
mode:
Diffstat (limited to 'src/base')
-rw-r--r--src/base/server.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/base/server.c b/src/base/server.c
index 10cde36..cdd1487 100644
--- a/src/base/server.c
+++ b/src/base/server.c
@@ -87,13 +87,9 @@ static proto_cmd_server_t *findCmdProto(client_t * client, char *msg)
thisCmd = &proto_cmd_list[i];
if (len >= thisCmd->len && strncmp(msg, thisCmd->name, thisCmd->len) == 0) {
- if (thisCmd->tux == 1 && client->tux == NULL) {
+ if ((thisCmd->tux == 1 && client->tux == NULL) ||
+ (thisCmd->tux == 0 && client->tux != NULL))
return NULL;
- }
-
- if (thisCmd->tux == 0 && client->tux != NULL) {
- return NULL;
- }
return thisCmd;
}