vfs_gpfs: Fix ENODATA for getacl on .snapshot dirs
authorRalph Wuerthner <ralph.wuerthner@de.ibm.com>
Tue, 11 Nov 2014 13:27:34 +0000 (14:27 +0100)
committerVolker Lendecke <vl@samba.org>
Tue, 28 Apr 2015 11:19:25 +0000 (13:19 +0200)
Fall back to POSIX ACLs in this case.

Signed-off-by: Ralph Wuerthner <ralph.wuerthner@de.ibm.com>
Reviewed-by: Christof Schmitt <cs@samba.org>
Reviewed-by: Volker Lendecke <vl@samba.org>
Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Tue Apr 28 13:19:25 CEST 2015 on sn-devel-104

source3/modules/vfs_gpfs.c

index aa0706016d1363c277a1948da05e5cebe6a2c27d..c8ba563f14cdc5dc7b293adbb9d634dd04b294ac 100644 (file)
@@ -438,6 +438,14 @@ static int gpfs_get_nfs4_acl(TALLOC_CTX *mem_ctx, const char *fname, SMB4ACL_T *
        if (gacl == NULL) {
                DEBUG(9, ("gpfs_getacl failed for %s with %s\n",
                           fname, strerror(errno)));
+               if (errno == ENODATA) {
+                       /*
+                        * GPFS returns ENODATA for snapshot
+                        * directories. Retry with POSIX ACLs check.
+                        */
+                       return 1;
+               }
+
                return -1;
        }