[Bug 50283] FILE_OPEN_REPARSE_POINT breaks error reporting for deletes of directories

WineHQ Bugzilla wine-bugs at winehq.org
Thu Feb 4 10:53:07 CST 2021


https://bugs.winehq.org/show_bug.cgi?id=50283

--- Comment #1 from Erich E. Hoover <erich.e.hoover at gmail.com> ---
It took me a while this weekend to figure out a way "around" this problem, but
the solution I came up with is really interesting:
===
    dir_fd = openat( fd, ".", O_RDONLY | O_DIRECTORY | O_NONBLOCK );
    if (dir_fd == -1)
        return -1;
    if (!(dir = fdopendir( dir_fd )))
    ...
    closedir( dir );
    close( dir_fd );
===
Essentially, we can "recreate" the fd with new permissions using openat() so
that it has the correct access rights for fdopendir().  This may be very useful
for implementing some other features...

Anyway, if you don't mind checking, this issue should now be fixed by staging
commit cfe1b94e0f53219cf292fea9b4618d909c282fbf.

-- 
Do not reply to this email, post in Bugzilla using the
above URL to reply.
You are receiving this mail because:
You are watching all bug changes.



More information about the wine-bugs mailing list