summaryrefslogtreecommitdiff
path: root/src/irc/irc-server.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/irc/irc-server.c')
-rw-r--r--src/irc/irc-server.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/irc/irc-server.c b/src/irc/irc-server.c
index 8ad22e8b5..1581bf931 100644
--- a/src/irc/irc-server.c
+++ b/src/irc/irc-server.c
@@ -832,12 +832,14 @@ server_disconnect (t_irc_server *server, int reconnect)
close (server->server_write);
server->server_write = -1;
-
if (server->sock4 >= 0)
close (server->sock4);
server->sock4 = -1;
+ if (server->unterminated_message)
+ free (server->unterminated_message);
server->unterminated_message = NULL;
+
server->is_connected = 0;
server->is_away = 0;
server->away_time = 0;