|
|
|
@ -260,8 +260,16 @@ static void tgc_phase1_timeout(void* arg) { |
|
|
|
} |
|
|
|
} |
|
|
|
u_free(ids); |
|
|
|
u_free(ids); |
|
|
|
|
|
|
|
|
|
|
|
for (int i = 0; i < gc->handle_count; i++) { conn_mgr_close(gc->handles[i]); gc->handles[i] = NULL; } |
|
|
|
int remaining = 0; |
|
|
|
gc->handle_count = 0; |
|
|
|
for (int i = 0; i < gc->handle_count; i++) { |
|
|
|
|
|
|
|
struct CONN_MGR_HANDLE* h = gc->handles[i]; |
|
|
|
|
|
|
|
if (h && conn_mgr_get_conn(h) != NULL) { |
|
|
|
|
|
|
|
gc->handles[remaining++] = h; |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
if (h) conn_mgr_close(h); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
gc->handle_count = remaining; |
|
|
|
|
|
|
|
|
|
|
|
if (gc->connected_count > 0) { |
|
|
|
if (gc->connected_count > 0) { |
|
|
|
DEBUG_INFO(DEBUG_CATEGORY_BGP, "%s: Phase1 done — %d connected, skipping Phase 2", TGC_ID, gc->connected_count); |
|
|
|
DEBUG_INFO(DEBUG_CATEGORY_BGP, "%s: Phase1 done — %d connected, skipping Phase 2", TGC_ID, gc->connected_count); |
|
|
|
|