aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorB. Watson <urchlay@slackware.uk>2026-03-21 18:36:28 -0400
committerB. Watson <urchlay@slackware.uk>2026-03-21 18:36:28 -0400
commitd29b04567a6083497ba827e8496210bbe3716dfa (patch)
tree14a4d0844e6da57fc3b4cc2518976af9ba1decd1 /src
parentf94ca39e2b9b5da0b6ec17e8096f6eeefbcf2cdb (diff)
downloadfujinet-chat-d29b04567a6083497ba827e8496210bbe3716dfa.tar.gz
Fix wrong command in "missing argument" err msg, when someone types e.g. space, enter in screens 1 & 2.
Diffstat (limited to 'src')
-rw-r--r--src/cmd.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/cmd.c b/src/cmd.c
index 106eda8..e0481c5 100644
--- a/src/cmd.c
+++ b/src/cmd.c
@@ -46,6 +46,7 @@ typedef struct {
OP DEOP VOICE DEVOICE KICK BAN KB IGNORE UNIGNORE MODE INVITE
*/
cmd_t command_defs[] = {
+ { "MSG", do_msg, 1 }, /* this must come first, do not move! */
{ "AWAY", do_away, 1 },
{ "ALERT", do_bell, 1 },
{ "CLICK", do_click, 0 },
@@ -59,7 +60,6 @@ cmd_t command_defs[] = {
{ "LIST", do_list, 1 },
{ "M", do_msg, 1 },
{ "ME", do_me, 1 },
- { "MSG", do_msg, 1 },
{ "NAMES", do_names, 0 },
{ "PART", do_part, 0 },
{ "PING", do_ping, 0 },
@@ -530,6 +530,7 @@ void cmd_rejoin_chans(void) {
/* args contains the destination, space, the msg */
void cmd_send_pm(char *args) {
+ cmd_def = command_defs; /* element 0 of command_defs must be MSG! */
arg1 = args;
do_msg();
}