diff options
author | Stef Walter <stefw@redhat.com> | 2015-11-10 12:18:30 +0100 |
---|---|---|
committer | Andreas Schneider <asn@cryptomilk.org> | 2016-05-02 15:28:24 +0200 |
commit | ffe8b98cc2ee975c461322f0f119a398d783bdf7 (patch) | |
tree | d42a115c4a0968d8c396fa2f031baaa5fbb510f1 /include/libssh/priv.h | |
parent | aa5c7c3b0ca36e415d095df55506df172e299ee2 (diff) | |
download | libssh-ffe8b98cc2ee975c461322f0f119a398d783bdf7.tar.gz libssh-ffe8b98cc2ee975c461322f0f119a398d783bdf7.tar.xz libssh-ffe8b98cc2ee975c461322f0f119a398d783bdf7.zip |
auth: Cleanup memory leak when using SSH agent
In Cockpit we've seen this memory leak:
at 0x4C2A9C7: calloc (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so)
by 0x5B76B03: ssh_userauth_agent (auth.c:778)
by 0x40DD5A: cockpit_ssh_authenticate (cockpitsshtransport.c:327)
BUG: https://red.libssh.org/issues/208
Signed-off-by: Stef Walter <stefw@redhat.com>
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
Diffstat (limited to 'include/libssh/priv.h')
-rw-r--r-- | include/libssh/priv.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/libssh/priv.h b/include/libssh/priv.h index b7a80fe2..9b34b247 100644 --- a/include/libssh/priv.h +++ b/include/libssh/priv.h @@ -361,5 +361,7 @@ int match_hostname(const char *host, const char *pattern, unsigned int len); #define CLOSE_SOCKET(s) do { if ((s) != SSH_INVALID_SOCKET) { _XCLOSESOCKET(s); (s) = SSH_INVALID_SOCKET;} } while(0) +void ssh_agent_state_free(void *data); + #endif /* _LIBSSH_PRIV_H */ /* vim: set ts=4 sw=4 et cindent: */ |