summaryrefslogtreecommitdiff
path: root/sftp-glob.c
diff options
context:
space:
mode:
authorBen Lindstrom <mouring@eviladmin.org>2002-07-07 22:10:15 +0000
committerBen Lindstrom <mouring@eviladmin.org>2002-07-07 22:10:15 +0000
commitc51b924a80a17d6cf47c25c2c118385d4ecc87c8 (patch)
tree140f5252d5b8bc0aca22225c2323781d6af6e78d /sftp-glob.c
parent8abe736dd7a27e4c2a42351287bacfd80ec42a7c (diff)
downloadopenssh-git-c51b924a80a17d6cf47c25c2c118385d4ecc87c8.tar.gz
- deraadt@cvs.openbsd.org 2002/07/04 04:15:33
[key.c monitor_wrap.c sftp-glob.c ssh-dss.c ssh-rsa.c] patch memory leaks; grendel@zeitbombe.org
Diffstat (limited to 'sftp-glob.c')
-rw-r--r--sftp-glob.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/sftp-glob.c b/sftp-glob.c
index 2deb0eb4..2a7cf141 100644
--- a/sftp-glob.c
+++ b/sftp-glob.c
@@ -23,7 +23,7 @@
*/
#include "includes.h"
-RCSID("$OpenBSD: sftp-glob.c,v 1.11 2002/06/30 21:59:45 deraadt Exp $");
+RCSID("$OpenBSD: sftp-glob.c,v 1.12 2002/07/04 04:15:33 deraadt Exp $");
#include "buffer.h"
#include "bufaux.h"
@@ -51,8 +51,10 @@ fudge_opendir(const char *path)
r = xmalloc(sizeof(*r));
- if (do_readdir(cur.conn, (char *)path, &r->dir))
+ if (do_readdir(cur.conn, (char *)path, &r->dir)) {
+ xfree(r);
return(NULL);
+ }
r->offset = 0;