summaryrefslogtreecommitdiff
path: root/src/core
diff options
context:
space:
mode:
Diffstat (limited to 'src/core')
-rw-r--r--src/core/servers-reconnect.c5
-rw-r--r--src/core/session.c1
2 files changed, 4 insertions, 2 deletions
diff --git a/src/core/servers-reconnect.c b/src/core/servers-reconnect.c
index baf047e9..4e497026 100644
--- a/src/core/servers-reconnect.c
+++ b/src/core/servers-reconnect.c
@@ -172,8 +172,9 @@ server_connect_copy_skeleton(SERVER_CONNECT_REC *src, int connect_info)
}
#define server_should_reconnect(server) \
- ((server)->connection_lost && ((server)->connrec->chatnet != NULL || \
- (!(server)->banned && !(server)->dns_error)))
+ ((server)->connection_lost && !(server)->session_reconnect && \
+ ((server)->connrec->chatnet != NULL || \
+ (!(server)->banned && !(server)->dns_error)))
#define sserver_connect_ok(rec, net) \
(!(rec)->banned && !(rec)->dns_error && (rec)->chatnet != NULL && \
diff --git a/src/core/session.c b/src/core/session.c
index 1a79e0e8..3d90a02c 100644
--- a/src/core/session.c
+++ b/src/core/session.c
@@ -189,6 +189,7 @@ static void session_save_server(SERVER_REC *server, CONFIG_REC *config,
server->handle = NULL;
server->connection_lost = TRUE;
+ server->session_reconnect = TRUE;
server_disconnect(server);
}