The Samba-Bugzilla – Attachment 2405 Details for
Bug 4536
Symlinks to dirs not being deleted
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
look (text/plain), 817 bytes, created by
Jeremy Allison
on 2007-04-24 07:52:55 UTC
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Jeremy Allison
Created:
2007-04-24 07:52:55 UTC
Size:
817 bytes
patch
obsolete
>Index: smbd/reply.c >=================================================================== >--- smbd/reply.c (revision 22498) >+++ smbd/reply.c (working copy) >@@ -3866,7 +3866,23 @@ > int ret; > SMB_STRUCT_STAT st; > >- ret = SMB_VFS_RMDIR(conn,directory); >+ /* Might be a symlink. */ >+ if(SMB_VFS_LSTAT(conn, directory, &st) != 0) { >+ return map_nt_error_from_unix(errno); >+ } >+ >+ if (S_ISLNK(st.st_mode)) { >+ /* Is what it points to a directory ? */ >+ if(SMB_VFS_STAT(conn, directory, &st) != 0) { >+ return map_nt_error_from_unix(errno); >+ } >+ if (!(S_ISDIR(st.st_mode))) { >+ return NT_STATUS_NOT_A_DIRECTORY; >+ } >+ ret = SMB_VFS_UNLINK(conn,directory); >+ } else { >+ ret = SMB_VFS_RMDIR(conn,directory); >+ } > if (ret == 0) { > notify_fname(conn, NOTIFY_ACTION_REMOVED, > FILE_NOTIFY_CHANGE_DIR_NAME,
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 4536
: 2405