Skip to content

Commit 65217ef

Browse files
committed
Fix Token Reconnection
1 parent 2f7e622 commit 65217ef

1 file changed

Lines changed: 1 addition & 7 deletions

File tree

src/webui.c

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6013,8 +6013,8 @@ static const char* _webui_generate_js_bridge(_webui_window_t* win, struct mg_con
60136013
}
60146014
if (win->token == 0) {
60156015
win->token = _webui_generate_random_uint32();
6016-
token = win->token;
60176016
}
6017+
token = win->token;
60186018
}
60196019
else {
60206020
// Multi client mode
@@ -11138,12 +11138,6 @@ static void _webui_connection_remove(_webui_window_t* win, struct mg_connection*
1113811138
#ifdef WEBUI_LOG
1113911139
_webui_log_debug("[Core]\t\t_webui_connection_remove() -> Removing client #%zu \n", i);
1114011140
#endif
11141-
// Reset Token
11142-
if (!_webui.config.multi_client) {
11143-
if (_webui_mutex_is_multi_client_token_valid(win, WEBUI_MUTEX_GET_STATUS, i)) {
11144-
win->token = 0;
11145-
}
11146-
}
1114711141
// Clear
1114811142
if (win->single_client == client) {
1114911143
win->single_client = NULL;

0 commit comments

Comments
 (0)