aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--degesch.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/degesch.c b/degesch.c
index df786f1..73263fd 100644
--- a/degesch.c
+++ b/degesch.c
@@ -4676,7 +4676,8 @@ irc_connect (struct server *s, bool *should_retry, struct error **e)
irc_reset_connection_timeouts (s);
irc_send (s, "NICK %s", nickname);
- irc_send (s, "USER %s 8 * :%s", username, realname);
+ // IRC servers may ignore the last argument if it's empty
+ irc_send (s, "USER %s 8 * :%s", username, *realname ? realname : " ");
// XXX: maybe we should wait for the first message from the server
// FIXME: the user may exist already after we've reconnected. Either