removed INVALID_COMMAND code
it was unused atp
This commit is contained in:
parent
cfa9f7bcca
commit
97ba473143
@ -36,8 +36,7 @@ extern "C" {
|
|||||||
#define WHY2_CHAT_CODE_ACCEPT_MESSAGES "code_000"
|
#define WHY2_CHAT_CODE_ACCEPT_MESSAGES "code_000"
|
||||||
#define WHY2_CHAT_CODE_PICK_USERNAME "code_001"
|
#define WHY2_CHAT_CODE_PICK_USERNAME "code_001"
|
||||||
#define WHY2_CHAT_CODE_SERVER_SIDE_QUIT_COMMUNICATION "code_002"
|
#define WHY2_CHAT_CODE_SERVER_SIDE_QUIT_COMMUNICATION "code_002"
|
||||||
#define WHY2_CHAT_CODE_INVALID_COMMAND "code_003"
|
#define WHY2_CHAT_CODE_INVALID_USERNAME "code_003"
|
||||||
#define WHY2_CHAT_CODE_INVALID_USERNAME "code_004"
|
|
||||||
|
|
||||||
//(SERVER -> CLIENT) CODES
|
//(SERVER -> CLIENT) CODES
|
||||||
#define WHY2_CHAT_CODE_EXIT "code_999"
|
#define WHY2_CHAT_CODE_EXIT "code_999"
|
||||||
|
@ -183,6 +183,10 @@ int main(void)
|
|||||||
} else if (command(line, WHY2_CHAT_COMMAND_LIST, &cmd_arg)) //HELP CMD
|
} else if (command(line, WHY2_CHAT_COMMAND_LIST, &cmd_arg)) //HELP CMD
|
||||||
{
|
{
|
||||||
why2_send_socket(WHY2_CHAT_CODE_LIST, NULL, listen_socket);
|
why2_send_socket(WHY2_CHAT_CODE_LIST, NULL, listen_socket);
|
||||||
|
} else
|
||||||
|
{
|
||||||
|
printf("\nInvalid command! Use \"" WHY2_CHAT_COMMAND_PREFIX WHY2_CHAT_COMMAND_HELP "\" for list of commands.\n\n>>> ");
|
||||||
|
fflush(stdout);
|
||||||
}
|
}
|
||||||
} else
|
} else
|
||||||
{
|
{
|
||||||
|
@ -772,10 +772,6 @@ void *why2_listen_server(void *socket)
|
|||||||
|
|
||||||
printf("%s%sEnter username (a-Z, 0-9; %d-%d characters):\n", asking_username++ > 0 ? WHY2_CLEAR_AND_GO_UP : "", WHY2_CLEAR_AND_GO_UP, min_uname, max_uname);
|
printf("%s%sEnter username (a-Z, 0-9; %d-%d characters):\n", asking_username++ > 0 ? WHY2_CLEAR_AND_GO_UP : "", WHY2_CLEAR_AND_GO_UP, min_uname, max_uname);
|
||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
} else if (strcmp(message, WHY2_CHAT_CODE_INVALID_COMMAND) == 0) //INVALID CMD
|
|
||||||
{
|
|
||||||
printf("\nInvalid command! Use \"" WHY2_CHAT_COMMAND_PREFIX WHY2_CHAT_COMMAND_HELP "\" for list of commands.\n\n");
|
|
||||||
fflush(stdout);
|
|
||||||
}
|
}
|
||||||
} else if (!continuing)
|
} else if (!continuing)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user