Apply patch from Max Rijevski fixing a memory leak when closing connections.
It also cleans up more when stopping tinc, helping tools like valgrind.
This commit is contained in:
parent
de032054de
commit
099bc56f53
2 changed files with 31 additions and 0 deletions
12
src/tincd.c
12
src/tincd.c
|
|
@ -510,7 +510,19 @@ end:
|
|||
remove_pid(pidfilename);
|
||||
#endif
|
||||
|
||||
if (identname) free(identname);
|
||||
if (netname) free(netname);
|
||||
if (pidfilename) free(pidfilename);
|
||||
if (logfilename) free(logfilename);
|
||||
if (myport) free(myport);
|
||||
if (device) free(device);
|
||||
if (confbase) free(confbase);
|
||||
|
||||
EVP_cleanup();
|
||||
ENGINE_cleanup();
|
||||
CRYPTO_cleanup_all_ex_data();
|
||||
ERR_remove_state(0);
|
||||
ERR_free_strings();
|
||||
|
||||
return status;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue