summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/irc/core/irc.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/irc/core/irc.c b/src/irc/core/irc.c
index 0743dae2..cf31814c 100644
--- a/src/irc/core/irc.c
+++ b/src/irc/core/irc.c
@@ -199,7 +199,8 @@ void irc_send_cmd_split(IRC_SERVER_REC *server, const char *cmd,
}
count = 0;
- g_string_truncate(nickstr, nickstr->len-1);
+ if (nickstr->len > 0)
+ g_string_truncate(nickstr, nickstr->len-1);
irc_send_cmdv(server, post == NULL ? "%s %s" : "%s %s %s",
pre, nickstr->str, post);
g_string_truncate(nickstr, 0);