Fix bug #8644 - vfs_acl_xattr and vfs_acl_tdb modules can fail to add inheritable...
authorJeremy Allison <jra@samba.org>
Fri, 2 Dec 2011 18:55:40 +0000 (10:55 -0800)
committerJeremy Allison <jra@samba.org>
Fri, 2 Dec 2011 21:13:03 +0000 (22:13 +0100)
If referring to an fsp sbuf can be left as an uninitialized variable,
causing the 'is_directory' variable to be false when it should be true.

Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Fri Dec  2 22:13:03 CET 2011 on sn-devel-104

source3/modules/vfs_acl_common.c

index 00ac2a193206537136bc349239289f56547023db..bf535c557bd3e8bf0011f417d297be5810a0ed93 100644 (file)
@@ -391,7 +391,7 @@ static NTSTATUS get_nt_acl_internal(vfs_handle_struct *handle,
                                return map_nt_error_from_unix(errno);
                        }
                }
-               is_directory = S_ISDIR(sbuf.st_ex_mode);
+               is_directory = S_ISDIR(psbuf->st_ex_mode);
 
                if (ignore_file_system_acl) {
                        TALLOC_FREE(pdesc_next);