conn_mgr: resume recovery when local sockets change

This commit is contained in:
evgeny committed 2026-10-01 00:51:17 +03:00
1 parent 8f5f2b089c
commit a65ef30d78
3 files changed
+16 -1

No files matched your search

+7
View File
@@ -52,6 +52,8 @@
#include "config_parser.h"
#include "../chat/chat_event.h"
#include "../chat/chat_sync.h"
#include "../routing_layer/topo_group.h"
#include "../routing_layer/conn_mgr.h"
#include "../lib/debug_config.h"
#include "../lib/mem.h"
#include "../lib/u_async.h"
@@ -238,6 +240,11 @@ static void auto_socket_post_sockets_changed(struct AUTO_SOCKET* as) {
need_reconnect = 1;
as->v4_addr_changed = 0; as->v6_addr_changed = 0;
struct TOPO_GROUPS* groups = as->instance->topo_groups;
for (struct ll_entry* e = groups && groups->group_list ? groups->group_list->head : NULL; e; e = e->next) {
struct TOPO_GROUP* group = (struct TOPO_GROUP*)e;
if (!group->stopping) conn_mgr_network_changed(group->conn_mgr);
}
chat_event_post(as->instance, CHAT_EVT_LOCAL_SOCKETS, NULL, 0);
if (need_reconnect) {