summaryrefslogtreecommitdiff
path: root/source/smbd/reply.c
diff options
context:
space:
mode:
authorVolker Lendecke <vlendec@samba.org>2007-08-15 13:44:34 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 12:29:49 -0500
commit0fecd8a0c3aaa64e137d2efd3f9cc7705837ea2a (patch)
tree2619ab15f96131518d280344b4236d5e5c1190b7 /source/smbd/reply.c
parentcedf7022c5c61ed5eb49bb1cb24b062858f7d2fd (diff)
downloadsamba-0fecd8a0c3aaa64e137d2efd3f9cc7705837ea2a.tar.gz
r24461: Fix Bug 4852, thank to anto <sistemac@prosoft.ba> for reporting it.
Diffstat (limited to 'source/smbd/reply.c')
-rw-r--r--source/smbd/reply.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/source/smbd/reply.c b/source/smbd/reply.c
index a95f2ec87ee..786fe9c6a16 100644
--- a/source/smbd/reply.c
+++ b/source/smbd/reply.c
@@ -1718,9 +1718,23 @@ void reply_open_and_X(connection_struct *conn, struct smb_request *req)
END_PROFILE(SMBopenX);
if (open_was_deferred(req->mid)) {
/* We have re-scheduled this call. */
+ END_PROFILE(SMBopenX);
+ return;
+ }
+ if (NT_STATUS_EQUAL(status, NT_STATUS_OBJECT_NAME_COLLISION)) {
+ /*
+ * We hit an existing file, and if we're returning DOS
+ * error codes OBJECT_NAME_COLLISION would map to
+ * ERRDOS/183, we need to return ERRDOS/80, see bug
+ * 4852.
+ */
+ reply_botherror(req, NT_STATUS_OBJECT_NAME_COLLISION,
+ ERRDOS, ERRfilexists);
+ END_PROFILE(SMBopenX);
return;
}
reply_nterror(req, status);
+ END_PROFILE(SMBopenX);
return;
}