summaryrefslogtreecommitdiffstats
path: root/source3
diff options
context:
space:
mode:
authorTim Prouty <tprouty@samba.org>2009-07-08 20:15:02 -0700
committerTim Prouty <tprouty@samba.org>2009-07-08 21:36:04 -0700
commitfbaa8497a5c8c209de9ca86bebf8387e6d33a608 (patch)
tree1e10a46dce85ea36039d905021a6012d45eeebf7 /source3
parent02aad05e0ed3e1d4790b323a94e43184f9c4e643 (diff)
downloadsamba-fbaa8497a5c8c209de9ca86bebf8387e6d33a608.tar.gz
samba-fbaa8497a5c8c209de9ca86bebf8387e6d33a608.tar.xz
samba-fbaa8497a5c8c209de9ca86bebf8387e6d33a608.zip
s3: Repace a char * with an smb_filename struct in reply_rmdir
Diffstat (limited to 'source3')
-rw-r--r--source3/smbd/reply.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/source3/smbd/reply.c b/source3/smbd/reply.c
index 837d17dc0b8..1fd4e50ea66 100644
--- a/source3/smbd/reply.c
+++ b/source3/smbd/reply.c
@@ -5541,7 +5541,7 @@ void reply_rmdir(struct smb_request *req)
req->flags2 & FLAGS2_DFS_PATHNAMES,
directory,
&smb_dname,
- &directory);
+ NULL);
if (!NT_STATUS_IS_OK(status)) {
if (NT_STATUS_EQUAL(status,NT_STATUS_PATH_NOT_COVERED)) {
reply_botherror(req, NT_STATUS_PATH_NOT_COVERED,
@@ -5552,7 +5552,12 @@ void reply_rmdir(struct smb_request *req)
goto out;
}
- dptr_closepath(directory, req->smbpid);
+ if (is_ntfs_stream_smb_fname(smb_dname)) {
+ reply_nterror(req, NT_STATUS_NOT_A_DIRECTORY);
+ goto out;
+ }
+
+ dptr_closepath(smb_dname->base_name, req->smbpid);
status = rmdir_internals(ctx, conn, smb_dname);
if (!NT_STATUS_IS_OK(status)) {
reply_nterror(req, status);
@@ -5561,7 +5566,7 @@ void reply_rmdir(struct smb_request *req)
reply_outbuf(req, 0, 0);
- DEBUG( 3, ( "rmdir %s\n", directory ) );
+ DEBUG(3, ("rmdir %s\n", smb_fname_str_dbg(smb_dname)));
out:
TALLOC_FREE(smb_dname);
END_PROFILE(SMBrmdir);