X-Git-Url: https://tinc-vpn.org/git/browse?a=blobdiff_plain;f=src%2Finvitation.c;h=c059ca3c2ca31d562f684851c0df8e2e98789145;hb=69e550f5950e31fb97eb4558c3d6e564211ab03a;hp=c667a6edfde72b8b49fe79b4a585fe7911d4890e;hpb=ca989c0c8b19901cbd7664a9d2b42aa85c9c176e;p=tinc diff --git a/src/invitation.c b/src/invitation.c index c667a6ed..c059ca3c 100644 --- a/src/invitation.c +++ b/src/invitation.c @@ -414,8 +414,10 @@ int cmd_invite(int argc, char *argv[]) { fclose(f); - if(connect_tincd(false)) { + if(connect_tincd(true)) { sendline(fd, "%d %d", CONTROL, REQ_RELOAD); + } else { + fprintf(stderr, "Could not signal the tinc daemon. Please restart or reload it manually.\n"); } } else { key = ecdsa_read_pem_private_key(f); @@ -1201,6 +1203,7 @@ next: aip = aip->ai_next; if(!aip) { + freeaddrinfo(ai); return 1; } } @@ -1246,6 +1249,8 @@ next: goto next; } + freeaddrinfo(ai); + // Check if the hash of the key he gave us matches the hash in the URL. char *fingerprint = line + 2; char hishash[64];