diff options
author | 2003-03-05 22:33:43 +0000 | |
---|---|---|
committer | 2003-03-05 22:33:43 +0000 | |
commit | ce850b032b66ce5ec1fcf20b26e03ac295ba3db5 (patch) | |
tree | 299a43373b41c270a5c1399d2a1942948eed2ae7 /usr.bin/ssh/channels.c | |
parent | delete blank lines (diff) | |
download | wireguard-openbsd-ce850b032b66ce5ec1fcf20b26e03ac295ba3db5.tar.xz wireguard-openbsd-ce850b032b66ce5ec1fcf20b26e03ac295ba3db5.zip |
fix memory leaks; from dlheine@suif.Stanford.EDU/CLOUSEAU; ok djm@
Diffstat (limited to 'usr.bin/ssh/channels.c')
-rw-r--r-- | usr.bin/ssh/channels.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/usr.bin/ssh/channels.c b/usr.bin/ssh/channels.c index 952c0d9c505..7ebca1a44f8 100644 --- a/usr.bin/ssh/channels.c +++ b/usr.bin/ssh/channels.c @@ -39,7 +39,7 @@ */ #include "includes.h" -RCSID("$OpenBSD: channels.c,v 1.186 2003/01/10 10:32:54 djm Exp $"); +RCSID("$OpenBSD: channels.c,v 1.187 2003/03/05 22:33:43 markus Exp $"); #include "ssh.h" #include "ssh1.h" @@ -1991,6 +1991,7 @@ channel_input_port_open(int type, u_int32_t seq, void *ctxt) c->remote_id = remote_id; } if (c == NULL) { + xfree(originator_string); packet_start(SSH_MSG_CHANNEL_OPEN_FAILURE); packet_put_int(remote_id); packet_send(); @@ -2575,6 +2576,7 @@ x11_input_open(int type, u_int32_t seq, void *ctxt) /* Send refusal to the remote host. */ packet_start(SSH_MSG_CHANNEL_OPEN_FAILURE); packet_put_int(remote_id); + xfree(remote_host); } else { /* Send a confirmation to the remote host. */ packet_start(SSH_MSG_CHANNEL_OPEN_CONFIRMATION); |