diff options
author | Andreas Schneider <asn@cryptomilk.org> | 2012-10-05 11:08:05 +0200 |
---|---|---|
committer | Andreas Schneider <asn@cryptomilk.org> | 2012-10-05 11:12:13 +0200 |
commit | b5c4b090da254c1ad3689983b0cb999b09aa3394 (patch) | |
tree | 11e258c3b98b3af3be8c19f32745f11d869b74c6 /src/sftp.c | |
parent | fd2064d0b4cdafc35a3430e7528e32a6abf2d513 (diff) | |
download | libssh-b5c4b090da254c1ad3689983b0cb999b09aa3394.tar.gz libssh-b5c4b090da254c1ad3689983b0cb999b09aa3394.tar.xz libssh-b5c4b090da254c1ad3689983b0cb999b09aa3394.zip |
sftp: Fix a memory on error in sftp_opendir().
Diffstat (limited to 'src/sftp.c')
-rw-r--r-- | src/sftp.c | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -893,6 +893,7 @@ sftp_dir sftp_opendir(sftp_session sftp, const char *path){ dir = malloc(sizeof(struct sftp_dir_struct)); if (dir == NULL) { ssh_set_error_oom(sftp->session); + free(file); return NULL; } ZERO_STRUCTP(dir); |