Fix bug #7733 - Invalid client DOS attributes on create can cause incorrect unix...
commit19343b779afef9048c7b52218351dd5c6a12061c
authorJeremy Allison <jra@samba.org>
Fri, 15 Oct 2010 20:30:07 +0000 (15 13:30 -0700)
committerJeremy Allison <jra@samba.org>
Sat, 16 Oct 2010 02:47:08 +0000 (15 19:47 -0700)
tree2ee3c943aec773d80cec29b27c19ad249937bf9d
parent50e84a8fa2cbb400415e57573f37b9012396d13d
Fix bug #7733 - Invalid client DOS attributes on create can cause incorrect unix mode_t to be generated.

It turns out a client can send an NTCreateX call for a new file, but specify
FILE_ATTRIBUTE_DIRECTORY in the attribute list. Windows silently strips this,
but we don't - causing the unix_mode() function to go through the "mode bits
for new directory" codepath, instead of the "mode bits for new file" codepath.

Jeremy.
(cherry picked from commit 92adb686372a9b67e47efb5b051bc351212f1780)
source3/smbd/open.c