"Ben Peddell" <klightspeed(a)netspace.net.au> writes:
> @@ -474,7 +475,9 @@ mode_t sd_to_mode( const struct security_descriptor *sd, const SID *owner )
> if (access & FILE_EXECUTE)
> denied_mode |= S_IXUSR|S_IXGRP|S_IXOTH;
> }
> - else if (security_equal_sid( sid, owner ))
> + else if (security_equal_sid( sid, owner ) ||
> + (security_equal_sid( user, owner ) &&
> + token_sid_present( current->process->token, sid, TRUE )))
> {
> unsigned int access = generic_file_map_access( ad_ace->Mask );
> if (access & FILE_READ_DATA)
> @@ -498,7 +501,9 @@ mode_t sd_to_mode( const struct security_descriptor *sd, const SID *owner )
> if (access & FILE_EXECUTE)
> new_mode |= S_IXUSR|S_IXGRP|S_IXOTH;
> }
> - else if (security_equal_sid( sid, owner ))
> + else if (security_equal_sid( sid, owner ) ||
> + (security_equal_sid( user, owner ) &&
> + token_sid_present( current->process->token, sid, FALSE )))
You should most likely set the group permissions too in that case.
--
Alexandre Julliard
julliard(a)winehq.org