[PATCH v2 1/4] server: Allow named pipes creation with device file as root directory.

Paul Gofman pgofman at codeweavers.com
Mon Nov 16 13:45:04 CST 2020


On 11/16/20 22:42, Alexandre Julliard wrote:
> Paul Gofman <pgofman at codeweavers.com> writes:
>
>> @@ -205,7 +206,13 @@ const struct object_attributes *get_req_object_attributes( const struct security
>>      }
>>      if (root && attr->rootdir && attr->name_len)
>>      {
>> -        if (!(*root = get_directory_obj( current->process, attr->rootdir ))) return NULL;
>> +        if (!(*root = get_handle_obj( current->process, attr->rootdir, 0, NULL ))) return NULL;
>> +        if (is_symlink_obj( *root ))
>> +        {
>> +            release_object( *root );
>> +            set_error( STATUS_OBJECT_TYPE_MISMATCH );
>> +            return NULL;
>> +        }
> Why do you need a special case for symlink objects?
>
Removing this check breaks the tests in om.c. Creating the objects with
symlinks as a root object fails on Windows, but will succeed on Wine as
the directory will get as an actual parent (from lookup_named_object()).




More information about the wine-devel mailing list