[PATCH] Start moving lp_posix_pathnames out of utility functions.
Jeremy Allison
jra at samba.org
Sat Dec 12 22:09:17 UTC 2015
On Sat, Dec 12, 2015 at 10:46:01PM +0100, Ralph Boehme wrote:
> On Fri, Dec 11, 2015 at 03:07:30PM -0800, Jeremy Allison wrote:
> > From the "I broke it so I should help fix it" department :-).
> >
> > Here is a patchset that ends up removing lp_posix_pathnames()
> > from ms_has_wild(), where it had no business being.
> >
> > If we're ever to make SMB2 unix extensions a reality
> > we need to have a handle-based posix pathname flag
> > for SMB2 processing, not grubbing around with a global
> > hidden behind a function (that can be left for the SMB1
> > code :-).
> >
> > Ultimate goal is to add a 'bool posix_paths' flag
> > to the struct smbd_smb2_request struct.
> >
> > Volker, let me know if this works for you ?
> >
> > Please review and push if you're happy.
>
> lgtm!
Thanks !
> While we're at it, maybe we can start splitting out POSIX pathnames
> capability out of file_struct.posix_open.FSP_POSIX_FLAGS_OPEN and add
> FSP_POSIX_FLAGS_PATHNAMES, please see attached patchset.
>
> Btw, it seems we somehow messed up the POSIX rename patchset and now
> open_file_ntcreate() doesn't set FSP_POSIX_FLAGS_RENAME when
> posix_open is true. I'll take a closer look tomorrow.
Wouldn't that be fixed by changing your patch to be:
--- a/source3/smbd/open.c
+++ b/source3/smbd/open.c
@@ -2703,7 +2703,9 @@ static NTSTATUS open_file_ntcreate(connection_struct *conn,
fsp->access_mask = open_access_mask; /* We change this to the
* requested access_mask after
* the open is done. */
- fsp->posix_flags |= posix_open ? FSP_POSIX_FLAGS_OPEN : 0;
+ if (posix_open) {
+ fsp->posix_flags |= FSP_POSIX_FLAGS_ALL;
+ }
if (timeval_is_zero(&request_time)) {
request_time = fsp->open_time;
As I think doing a POSIX open should set all posix flags
on the fsp (at least for now).
More information about the samba-technical
mailing list