diff options
Diffstat (limited to 'source4/ntvfs/posix')
-rw-r--r-- | source4/ntvfs/posix/pvfs_dirlist.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/source4/ntvfs/posix/pvfs_dirlist.c b/source4/ntvfs/posix/pvfs_dirlist.c index 0137424dc4..85c307a1b2 100644 --- a/source4/ntvfs/posix/pvfs_dirlist.c +++ b/source4/ntvfs/posix/pvfs_dirlist.c @@ -89,11 +89,6 @@ NTSTATUS pvfs_list(struct pvfs_state *pvfs, struct pvfs_filename *name, struct p return NT_STATUS_NO_MEMORY; } - dir->names = talloc(dir, 0); - if (!dir->names) { - return NT_STATUS_NO_MEMORY; - } - odir = opendir(name->full_name); if (!odir) { return pvfs_map_errno(pvfs, errno); @@ -110,7 +105,7 @@ NTSTATUS pvfs_list(struct pvfs_state *pvfs, struct pvfs_filename *name, struct p if (dir->count >= allocated) { allocated = (allocated + 100) * 1.2; - dir->names = talloc_realloc_p(dir->names, const char *, allocated); + dir->names = talloc_realloc_p(dir, dir->names, const char *, allocated); if (!dir->names) { closedir(odir); return NT_STATUS_NO_MEMORY; |