dokan-dev / dokany

User mode file system library for windows with FUSE Wrapper
http://dokan-dev.github.io
5.21k stars 661 forks source link

rmdir is not working #1064

Closed Temtaime closed 2 years ago

Temtaime commented 2 years ago

Environment

Check List

Description

Hi. Seems that DeleteDirectory is not working at all because of missed rmdir call. See https://github.com/dokan-dev/dokany/blob/master/dokan_fuse/src/fusemain.cpp#L464

Liryna commented 2 years ago

Hi @Temtaime ,

Here is the rmdir call: https://github.com/dokan-dev/dokany/blob/master/dokan_fuse/src/fusemain.cpp#L172

Temtaime commented 2 years ago

Ok, i was wrong. I did not found where DeleteOnClose is set and thought that this path is not executed for regular directory deletion. Finally i installed cygwin to run fuse mirror and seems that it works and deletes the directories. But in my program i'm getting "invalid msdos function" from explorer and cannot find why it refuses to call rmdir at all. Maybe can you shed light upon rmdir calling ? Which functions are needed for it to work? I already have getattr and readdir.

Temtaime commented 2 years ago

log.txt I grab a log but cannot find anything particular ☹️

Temtaime commented 2 years ago

Found it. For those who get "invalid ms-dos function" upon deleting a file - set 0777 permissions on st_mode in getattr function.