|
@ -653,6 +653,9 @@ size_t clear_peer_list (struct peer_info ** peer_list) { |
|
|
size_t retval = 0; |
|
|
size_t retval = 0; |
|
|
|
|
|
|
|
|
HASH_ITER(hh, *peer_list, scan, tmp) { |
|
|
HASH_ITER(hh, *peer_list, scan, tmp) { |
|
|
|
|
|
if (scan->purgeable == SN_UNPURGEABLE && scan->ip_addr) { |
|
|
|
|
|
free(scan->ip_addr); |
|
|
|
|
|
} |
|
|
HASH_DEL(*peer_list, scan); |
|
|
HASH_DEL(*peer_list, scan); |
|
|
mgmt_event_post(N2N_EVENT_PEER,N2N_EVENT_PEER_CLEAR,scan); |
|
|
mgmt_event_post(N2N_EVENT_PEER,N2N_EVENT_PEER_CLEAR,scan); |
|
|
/* FIXME: generates events for more than just p2p */ |
|
|
/* FIXME: generates events for more than just p2p */ |
|
|