git.samba.org
/
metze
/
samba
/
wip.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3d7cde5
)
Make test for open modes more robust against other bits.
author
Jeremy Allison
<jra@samba.org>
Wed, 25 Feb 2009 21:00:44 +0000
(13:00 -0800)
committer
Jeremy Allison
<jra@samba.org>
Wed, 25 Feb 2009 21:00:44 +0000
(13:00 -0800)
Jeremy.
source3/smbd/trans2.c
patch
|
blob
|
history
diff --git
a/source3/smbd/trans2.c
b/source3/smbd/trans2.c
index 369830b086f53cf63e373d39f671904054455a36..ee1dda98b22c3ca3d982e60ddc71dadd49921447 100644
(file)
--- a/
source3/smbd/trans2.c
+++ b/
source3/smbd/trans2.c
@@
-6423,7
+6423,7
@@
static NTSTATUS smb_posix_open(connection_struct *conn,
create_disp = FILE_OVERWRITE_IF;
} else if((wire_open_mode & SMB_O_CREAT) == SMB_O_CREAT) {
create_disp = FILE_OPEN_IF;
- } else if (
wire_open_mode
== 0) {
+ } else if (
(wire_open_mode & (SMB_O_CREAT | SMB_O_EXCL | SMB_O_TRUNC))
== 0) {
create_disp = FILE_OPEN;
} else {
DEBUG(5,("smb_posix_open: invalid create mode 0x%x\n",