Skip to content

Commit

Permalink
Fix auto IP tracking
Browse files Browse the repository at this point in the history
  • Loading branch information
shaxxx authored and hamishcoleman committed Aug 27, 2023
1 parent f791531 commit 7c10788
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/sn_utils.c
Original file line number Diff line number Diff line change
Expand Up @@ -1145,6 +1145,9 @@ static int update_edge (n2n_sn_t *sss,
/* Known */
if(auth_edge(&(scan->auth), &(reg->auth), answer_auth, comm) == 0) {
if(!sock_equal(sender_sock, &(scan->sock))) {
scan->dev_addr.net_addr = reg->dev_addr.net_addr;
scan->dev_addr.net_bitlen = reg->dev_addr.net_bitlen;
memcpy((char*)scan->dev_desc, reg->dev_desc, N2N_DESC_SIZE);
memcpy(&(scan->sock), sender_sock, sizeof(n2n_sock_t));
scan->socket_fd = socket_fd;
scan->last_cookie = reg->cookie;
Expand Down

0 comments on commit 7c10788

Please sign in to comment.