From: Jeremy Allison Date: Thu, 14 Apr 2005 21:01:01 +0000 (+0000) Subject: r6344: Fix bug #2601 - it seems that DOS_OPEN_EXEC does mean readonly. Needed X-Git-Tag: samba-misc-tags/initial-v3-0-unstable~4940 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=77c0ade9fa1e6a31739823be0faa50799bac2775;p=thirdparty%2Fsamba.git r6344: Fix bug #2601 - it seems that DOS_OPEN_EXEC does mean readonly. Needed for Win9x and OS/2 clients. More Samba4 tests against W2k3 will be needed to confirm this but in the meantime get it up and running. Jeremy. --- diff --git a/source/smbd/open.c b/source/smbd/open.c index 559994ca46c..a3bc4a922d3 100644 --- a/source/smbd/open.c +++ b/source/smbd/open.c @@ -1159,6 +1159,7 @@ files_struct *open_file_shared1(connection_struct *conn,char *fname, SMB_STRUCT_ append does not mean the same thing under dos and unix */ switch (GET_OPEN_MODE(share_mode)) { + case DOS_OPEN_EXEC: case DOS_OPEN_RDONLY: flags = O_RDONLY; if (desired_access == 0) @@ -1176,7 +1177,6 @@ files_struct *open_file_shared1(connection_struct *conn,char *fname, SMB_STRUCT_ desired_access = FILE_READ_DATA|FILE_WRITE_DATA; break; case DOS_OPEN_RDWR: - case DOS_OPEN_EXEC: flags = O_RDWR; if (desired_access == 0) desired_access = FILE_READ_DATA|FILE_WRITE_DATA;