From 634dfd41e84a40b41f2a8251b849c8effdea2a93 Mon Sep 17 00:00:00 2001 From: Timo Sirainen Date: Mon, 18 Dec 2000 14:00:26 +0000 Subject: [PATCH] quit messages shouldn't crash :) git-svn-id: http://svn.irssi.org/repos/irssi/trunk@1008 dbcabf3a-b0e7-0310-adc4-f8d773084564 --- src/fe-common/core/fe-messages.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/fe-common/core/fe-messages.c b/src/fe-common/core/fe-messages.c index 39e59f27..8553c2c5 100644 --- a/src/fe-common/core/fe-messages.c +++ b/src/fe-common/core/fe-messages.c @@ -245,7 +245,7 @@ static void sig_message_quit(SERVER_REC *server, const char *nick, once = settings_get_bool("show_quit_once"); count = 0; windows = NULL; - chans = !once ? NULL : g_string_new(NULL); + chans = g_string_new(NULL); for (tmp = server->channels; tmp != NULL; tmp = tmp->next) { CHANNEL_REC *rec = tmp->data; @@ -289,8 +289,7 @@ static void sig_message_quit(SERVER_REC *server, const char *nick, count <= 1 ? IRCTXT_QUIT : IRCTXT_QUIT_ONCE, nick, address, reason, chans->str); } - if (chans != NULL) - g_string_free(chans, TRUE); + g_string_free(chans, TRUE); } static void sig_message_kick(SERVER_REC *server, const char *channel,