fix /reconnect now

This fixes #1846
Issue introduced by a0aa26b6fa

Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
This commit is contained in:
Steffen Jaeckel
2023-05-10 15:07:07 +02:00
parent 08d68d329b
commit 8cd53acfd7
7 changed files with 22 additions and 3 deletions

View File

@@ -6575,7 +6575,8 @@ cmd_reconnect(ProfWin* window, const char* const command, gchar** args)
int intval = 0;
char* err_msg = NULL;
if (g_strcmp0(value, "now") == 0) {
session_reconnect_now();
cons_show("Reconnecting now.");
cl_ev_reconnect();
} else if (strtoi_range(value, &intval, 0, INT_MAX, &err_msg)) {
prefs_set_reconnect(intval);
if (intval == 0) {