diff options
Diffstat (limited to 'source3/smbd')
-rw-r--r-- | source3/smbd/pysmbd.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source3/smbd/pysmbd.c b/source3/smbd/pysmbd.c index 8a5bde1090..6bef8af66d 100644 --- a/source3/smbd/pysmbd.c +++ b/source3/smbd/pysmbd.c @@ -129,9 +129,9 @@ static NTSTATUS set_nt_acl_no_snum(const char *fname, flags = O_RDONLY; #endif - fsp->fh->fd = SMB_VFS_OPEN(conn, smb_fname, fsp, flags, 00400); + fsp->fh->fd = SMB_VFS_OPEN(conn, smb_fname, fsp, O_RDWR, 00400); if (fsp->fh->fd == -1 && errno == EISDIR) { - fsp->fh->fd = SMB_VFS_OPEN(conn, smb_fname, fsp, O_RDWR, 00400); + fsp->fh->fd = SMB_VFS_OPEN(conn, smb_fname, fsp, flags, 00400); } if (fsp->fh->fd == -1) { printf("open: error=%d (%s)\n", errno, strerror(errno)); |