diff options
author | Damien Miller <djm@mindrot.org> | 2003-03-10 11:21:17 +1100 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2003-03-10 11:21:17 +1100 |
commit | 0011138d47e284273ba77415f7162aaab60d9a44 (patch) | |
tree | c175bfc5d470a641dfc727490eec5765903992d2 /sftp-client.c | |
parent | 73942b9d54ec71ae76e58d5bf3b06f094bfc3002 (diff) |
- (djm) OpenBSD CVS Sync
- markus@cvs.openbsd.org 2003/03/05 22:33:43
[channels.c monitor.c scp.c session.c sftp-client.c sftp-int.c]
[sftp-server.c ssh-add.c sshconnect2.c]
fix memory leaks; from dlheine@suif.Stanford.EDU/CLOUSEAU; ok djm@
Diffstat (limited to 'sftp-client.c')
-rw-r--r-- | sftp-client.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sftp-client.c b/sftp-client.c index 8c12dae1..3b3279e6 100644 --- a/sftp-client.c +++ b/sftp-client.c @@ -28,7 +28,7 @@ /* XXX: copy between two remote sites */ #include "includes.h" -RCSID("$OpenBSD: sftp-client.c,v 1.41 2003/01/14 10:58:00 djm Exp $"); +RCSID("$OpenBSD: sftp-client.c,v 1.42 2003/03/05 22:33:43 markus Exp $"); #include "openbsd-compat/sys-queue.h" @@ -374,6 +374,7 @@ do_lsreaddir(struct sftp_conn *conn, char *path, int printflag, error("Couldn't read directory: %s", fx2txt(status)); do_close(conn, handle, handle_len); + xfree(handle); return(status); } } else if (type != SSH2_FXP_NAME) @@ -1113,6 +1114,8 @@ do_upload(struct sftp_conn *conn, char *local_path, char *remote_path, remote_path, fx2txt(status)); do_close(conn, handle, handle_len); close(local_fd); + xfree(data); + xfree(ack); goto done; } debug3("In write loop, ack for %u %u bytes at %llu", |