summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/core/servers.c3
-rw-r--r--src/irc/core/irc.c3
2 files changed, 4 insertions, 2 deletions
diff --git a/src/core/servers.c b/src/core/servers.c
index 725010a8..89f32aea 100644
--- a/src/core/servers.c
+++ b/src/core/servers.c
@@ -334,6 +334,9 @@ void server_disconnect(SERVER_REC *server)
g_return_if_fail(IS_SERVER(server));
+ if (server->disconnected)
+ return;
+
if (server->connect_tag != -1) {
/* still connecting to server.. */
if (server->connect_pid != -1)
diff --git a/src/irc/core/irc.c b/src/irc/core/irc.c
index 64ce4af6..f2827132 100644
--- a/src/irc/core/irc.c
+++ b/src/irc/core/irc.c
@@ -376,8 +376,7 @@ static void irc_parse_incoming(SERVER_REC *server)
letting other tasks to run. */
count = 0;
server_ref(server);
- while (!server->disconnected &&
- irc_receive_line(server, &str, count < MAX_SOCKET_READS) > 0) {
+ while (irc_receive_line(server, &str, count < MAX_SOCKET_READS) > 0) {
rawlog_input(server->rawlog, str);
signal_emit_id(signal_server_incoming, 2, server, str);