Did not notice that this introduces 100% failure all in itself.
This reverts commit
70c37954649fbc4fc2d0820d5d422f96144071f9.
Change-Id: If27762e2ffa9afc3857446a733ee3a8751fe6292
Reviewed-on: http://review.whamcloud.com/10151
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Tested-by: Oleg Drokin <oleg.drokin@intel.com>
!(attr->ia_mode & S_ISGID))))
attr->ia_valid |= ATTR_FORCE;
!(attr->ia_mode & S_ISGID))))
attr->ia_valid |= ATTR_FORCE;
- if ((attr->ia_valid & ATTR_MODE) &&
- (mode & S_ISUID) &&
+ if ((mode & S_ISUID) &&
!(attr->ia_mode & S_ISUID) &&
!(attr->ia_valid & ATTR_KILL_SUID))
attr->ia_valid |= ATTR_KILL_SUID;
!(attr->ia_mode & S_ISUID) &&
!(attr->ia_valid & ATTR_KILL_SUID))
attr->ia_valid |= ATTR_KILL_SUID;
- if ((attr->ia_valid & ATTR_MODE) &&
- ((mode & (S_ISGID|S_IXGRP)) == (S_ISGID|S_IXGRP)) &&
+ if (((mode & (S_ISGID|S_IXGRP)) == (S_ISGID|S_IXGRP)) &&
!(attr->ia_mode & S_ISGID) &&
!(attr->ia_valid & ATTR_KILL_SGID))
attr->ia_valid |= ATTR_KILL_SGID;
!(attr->ia_mode & S_ISGID) &&
!(attr->ia_valid & ATTR_KILL_SGID))
attr->ia_valid |= ATTR_KILL_SGID;
+++ /dev/null
-LU-4924 - chmod g+s, touch should not clear sgid bit
-
- $ mkdir 4924
- $ cd 4924
- $ touch f
- $ chmod u=rwx,g=rwxs f
- $ ls -l f | awk -- '{ print $1, $3, $4 }'
- > -rwxrwsr-- root root
- $ touch f
- $ ls -l f | awk -- '{ print $1, $3, $4 }'
- > -rwxrwsr-- root root
- $ cd ..
- $ rm -rf 4924
run_acl_subtest 2561_zfs || error "LU-2561 zfs test failed"
fi
run_acl_subtest 2561_zfs || error "LU-2561 zfs test failed"
fi
- run_acl_subtest 4924 || error "LU-4924 test failed"
-
cd $SAVE_PWD
umask $SAVE_UMASK
cd $SAVE_PWD
umask $SAVE_UMASK