- djm@cvs.openbsd.org 2006/03/19 02:22:56

[sftp.c]
     more memory leaks detected by Coverity via elad AT netbsd.org;
     deraadt@ ok
This commit is contained in:
Damien Miller 2006-03-26 13:51:44 +11:00
parent 6f98a1fea7
commit e0b90a6766
2 changed files with 8 additions and 1 deletions

View File

@ -18,6 +18,10 @@
[serverloop.c] [serverloop.c]
memory leaks detected by Coverity via elad AT netbsd.org; memory leaks detected by Coverity via elad AT netbsd.org;
ok deraadt@ dtucker@ ok deraadt@ dtucker@
- djm@cvs.openbsd.org 2006/03/19 02:22:56
[sftp.c]
more memory leaks detected by Coverity via elad AT netbsd.org;
deraadt@ ok
20060325 20060325
- OpenBSD CVS Sync - OpenBSD CVS Sync
@ -4275,4 +4279,4 @@
- (djm) Trim deprecated options from INSTALL. Mention UsePAM - (djm) Trim deprecated options from INSTALL. Mention UsePAM
- (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu - (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu
$Id: ChangeLog,v 1.4246 2006/03/26 02:51:08 djm Exp $ $Id: ChangeLog,v 1.4247 2006/03/26 02:51:44 djm Exp $

3
sftp.c
View File

@ -1289,6 +1289,7 @@ interactive_loop(int fd_in, int fd_out, char *file1, char *file2)
if (parse_dispatch_command(conn, cmd, &pwd, 1) != 0) { if (parse_dispatch_command(conn, cmd, &pwd, 1) != 0) {
xfree(dir); xfree(dir);
xfree(pwd); xfree(pwd);
xfree(conn);
return (-1); return (-1);
} }
} else { } else {
@ -1301,6 +1302,7 @@ interactive_loop(int fd_in, int fd_out, char *file1, char *file2)
err = parse_dispatch_command(conn, cmd, &pwd, 1); err = parse_dispatch_command(conn, cmd, &pwd, 1);
xfree(dir); xfree(dir);
xfree(pwd); xfree(pwd);
xfree(conn);
return (err); return (err);
} }
xfree(dir); xfree(dir);
@ -1365,6 +1367,7 @@ interactive_loop(int fd_in, int fd_out, char *file1, char *file2)
break; break;
} }
xfree(pwd); xfree(pwd);
xfree(conn);
#ifdef USE_LIBEDIT #ifdef USE_LIBEDIT
if (el != NULL) if (el != NULL)