mirror of
https://git.libssh.org/projects/libssh.git
synced 2025-11-29 01:03:57 +03:00
bind: Correctly free all memory in ssh_bind_free().
Thanks to Jacob Baines.
This commit is contained in:
10
src/bind.c
10
src/bind.c
@@ -341,11 +341,15 @@ void ssh_bind_free(ssh_bind sshbind){
|
|||||||
|
|
||||||
/* options */
|
/* options */
|
||||||
SAFE_FREE(sshbind->banner);
|
SAFE_FREE(sshbind->banner);
|
||||||
|
SAFE_FREE(sshbind->bindaddr);
|
||||||
|
|
||||||
SAFE_FREE(sshbind->dsakey);
|
SAFE_FREE(sshbind->dsakey);
|
||||||
SAFE_FREE(sshbind->rsakey);
|
SAFE_FREE(sshbind->rsakey);
|
||||||
SAFE_FREE(sshbind->dsa);
|
SAFE_FREE(sshbind->ecdsakey);
|
||||||
SAFE_FREE(sshbind->rsa);
|
|
||||||
SAFE_FREE(sshbind->bindaddr);
|
ssh_key_free(sshbind->dsa);
|
||||||
|
ssh_key_free(sshbind->rsa);
|
||||||
|
ssh_key_free(sshbind->ecdsa);
|
||||||
|
|
||||||
for (i = 0; i < 10; i++) {
|
for (i = 0; i < 10; i++) {
|
||||||
if (sshbind->wanted_methods[i]) {
|
if (sshbind->wanted_methods[i]) {
|
||||||
|
|||||||
Reference in New Issue
Block a user