diff options
| author | B. Watson <urchlay@slackware.uk> | 2026-03-18 19:15:05 -0400 |
|---|---|---|
| committer | B. Watson <urchlay@slackware.uk> | 2026-03-18 19:15:05 -0400 |
| commit | 8ae3acb491f07b4dc844dc7973efccdc6ca6a233 (patch) | |
| tree | 3b7e42cd8f1c7bc3f3d2249579a8d34a0b0ccc8d /src | |
| parent | 858b68b23b3e7845a5a8b78fde832ccec5c4f3cd (diff) | |
| download | fujinet-chat-8ae3acb491f07b4dc844dc7973efccdc6ca6a233.tar.gz | |
Temporary fix for "USER: Not enough parameters".
Diffstat (limited to 'src')
| -rw-r--r-- | src/irc.c | 11 |
1 files changed, 11 insertions, 0 deletions
@@ -273,6 +273,17 @@ static void do_join(void) { } static void do_nick(void) { + /* Do not overwrite conf->nick with bogus data! sometimes when + we get disconnected, upon reconnect we get a partial message. + if it's a NICK, missing its destination argument, we end up + blowing away conf->nick, and subsequent reconnect attempts + fail with "USER: not enough parameters". This is purely + a band-aid; a proper solution involves rewriting parse_msg() + so it knows how many args each msg type needs, and refuses to + parse invalid ones. */ + if(!msg_dest || !*msg_dest || *msg_dest == ' ') + return; + // ind_act_none(); if(streq_i(conf->nick, msg_src)) { scr_print_active("You are "); |
