aboutsummaryrefslogtreecommitdiff
path: root/libssh/kex.c
diff options
context:
space:
mode:
authormilo <milo.sshiva@gmail.com>2009-07-28 18:01:07 +0200
committerAndreas Schneider <mail@cynapses.org>2009-08-06 10:29:36 +0200
commit1b9676a0cc28e5dab6cea5ffe7c9fcd0fa10d9d8 (patch)
tree695104dd824160af03c02826f0e370ec524d0204 /libssh/kex.c
parentf4b3ef7604eac4a564159879ee2a5edb04a2c223 (diff)
downloadlibssh-1b9676a0cc28e5dab6cea5ffe7c9fcd0fa10d9d8.tar.gz
libssh-1b9676a0cc28e5dab6cea5ffe7c9fcd0fa10d9d8.tar.xz
libssh-1b9676a0cc28e5dab6cea5ffe7c9fcd0fa10d9d8.zip
Fix possible memory corruption (#14)
Signed-off-by: Andreas Schneider <mail@cynapses.org>
Diffstat (limited to 'libssh/kex.c')
-rw-r--r--libssh/kex.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libssh/kex.c b/libssh/kex.c
index 5927ba99..dd391ca3 100644
--- a/libssh/kex.c
+++ b/libssh/kex.c
@@ -421,8 +421,8 @@ int ssh_send_kex(SSH_SESSION *session, int server_kex) {
leave_function();
return 0;
error:
- buffer_free(session->out_buffer);
- buffer_free(session->out_hashbuf);
+ buffer_reinit(session->out_buffer);
+ buffer_reinit(session->out_hashbuf);
string_free(str);
leave_function();