Odd Samba behavior using Windows XP client API RemoveDirectory function
I'm having problems with a utility I wrote deleting folders from a
Thecus N4100 Samba based fileserver. I do not have access or control
over its Samba config file and this may not be a Samba problem but
perhaps someone here can point me in the right direction???
When I issue a Windows API RemoveDirectory function against an empty
folder residing on a Samba share, the function returns with a success
return code but does not delete the folder! This is a known problem
and is documented in the Cygwin rmdir command as occurring when the
folder is flagged as read-only, which is the Samba default.
When I issue a GetFileAttributes call the result does not show the
folder as being read-only, but looking at its properties under
explorer shows that it is!!!
There seems to be no way to programmatically delete such a folder, yet
when I delete it using the explorer it is removed without problem.
This led me to try the SHFileOperation function with the OF_DELETE
operator, thinking that if the shell could delete it then this might
work. Got even weirder results!!! The folder disappears from the
browser for 5 to 10 seconds then reappears!!!
There's got to be a way to delete such an empty folder since the
Windows Explorer can do it. Any tips or pointers would be much
----== Posted via Newsfeeds.Com - Unlimited-Unrestricted-Secure Usenet News==----
[url]http://www.newsfeeds.com[/url] The #1 Newsgroup Service in the World! >100,000 Newsgroups
---= East/West-Coast Server Farms - Total Privacy via Encryption =---