struct smb_filename *smb_fname = NULL;
char *name = NULL;
NTSTATUS status;
- uint32_t ucf_flags = 0;
+ uint32_t ucf_flags = (lp_posix_pathnames() ? UCF_POSIX_PATHNAMES : 0);
TALLOC_CTX *ctx = talloc_tos();
START_PROFILE(SMBcheckpath);
size = 0;
mtime = 0;
} else {
- uint32_t ucf_flags = 0;
+ uint32_t ucf_flags = (lp_posix_pathnames() ?
+ UCF_POSIX_PATHNAMES : 0);
status = filename_convert(ctx,
conn,
req->flags2 & FLAGS2_DFS_PATHNAMES,
time_t mtime;
const char *p;
NTSTATUS status;
- uint32_t ucf_flags = 0;
+ uint32_t ucf_flags = (lp_posix_pathnames() ? UCF_POSIX_PATHNAMES : 0);
TALLOC_CTX *ctx = talloc_tos();
START_PROFILE(SMBsetatr);
/* dirtype &= ~FILE_ATTRIBUTE_DIRECTORY; */
if (status_len == 0) {
- uint32_t ucf_flags = UCF_ALWAYS_ALLOW_WCARD_LCOMP;
+ uint32_t ucf_flags = UCF_ALWAYS_ALLOW_WCARD_LCOMP |
+ (lp_posix_pathnames() ? UCF_POSIX_PATHNAMES : 0);
nt_status = filename_convert(ctx, conn,
req->flags2 & FLAGS2_DFS_PATHNAMES,
path,
uint32_t create_options = 0;
uint32_t private_flags = 0;
NTSTATUS status;
- uint32_t ucf_flags = UCF_PREP_CREATEFILE;
+ uint32_t ucf_flags = UCF_PREP_CREATEFILE |
+ (lp_posix_pathnames() ? UCF_POSIX_PATHNAMES : 0);
TALLOC_CTX *ctx = talloc_tos();
START_PROFILE(SMBopen);
uint32_t create_disposition;
uint32_t create_options = 0;
uint32_t private_flags = 0;
- uint32_t ucf_flags = UCF_PREP_CREATEFILE;
+ uint32_t ucf_flags = UCF_PREP_CREATEFILE |
+ (lp_posix_pathnames() ? UCF_POSIX_PATHNAMES : 0);
TALLOC_CTX *ctx = talloc_tos();
START_PROFILE(SMBopenX);
uint32_t share_mode = FILE_SHARE_READ|FILE_SHARE_WRITE;
uint32_t create_disposition;
uint32_t create_options = 0;
- uint32_t ucf_flags = UCF_PREP_CREATEFILE;
+ uint32_t ucf_flags = UCF_PREP_CREATEFILE |
+ (lp_posix_pathnames() ? UCF_POSIX_PATHNAMES : 0);
TALLOC_CTX *ctx = talloc_tos();
START_PROFILE(SMBcreate);
char *s;
NTSTATUS status;
int i;
- uint32_t ucf_flags = UCF_PREP_CREATEFILE;
+ uint32_t ucf_flags = UCF_PREP_CREATEFILE |
+ (lp_posix_pathnames() ? UCF_POSIX_PATHNAMES : 0);
TALLOC_CTX *ctx = talloc_tos();
START_PROFILE(SMBctemp);
uint32_t dirtype;
NTSTATUS status;
bool path_contains_wcard = False;
- uint32_t ucf_flags = UCF_COND_ALLOW_WCARD_LCOMP;
+ uint32_t ucf_flags = UCF_COND_ALLOW_WCARD_LCOMP |
+ (lp_posix_pathnames() ? UCF_POSIX_PATHNAMES : 0);
TALLOC_CTX *ctx = talloc_tos();
START_PROFILE(SMBunlink);
struct smb_filename *smb_dname = NULL;
char *directory = NULL;
NTSTATUS status;
- uint32_t ucf_flags = UCF_PREP_CREATEFILE;
+ uint32_t ucf_flags = UCF_PREP_CREATEFILE |
+ (lp_posix_pathnames() ? UCF_POSIX_PATHNAMES : 0);
TALLOC_CTX *ctx = talloc_tos();
START_PROFILE(SMBmkdir);
TALLOC_CTX *ctx = talloc_tos();
files_struct *fsp = NULL;
int info = 0;
- uint32_t ucf_flags = 0;
+ uint32_t ucf_flags = (lp_posix_pathnames() ? UCF_POSIX_PATHNAMES : 0);
struct smbd_server_connection *sconn = req->sconn;
START_PROFILE(SMBrmdir);
TALLOC_CTX *ctx = talloc_tos();
struct smb_filename *smb_fname_src = NULL;
struct smb_filename *smb_fname_dst = NULL;
- uint32_t src_ucf_flags = lp_posix_pathnames() ? UCF_UNIX_NAME_LOOKUP : UCF_COND_ALLOW_WCARD_LCOMP;
- uint32_t dst_ucf_flags = UCF_SAVE_LCOMP | (lp_posix_pathnames() ? 0 : UCF_COND_ALLOW_WCARD_LCOMP);
+ uint32_t src_ucf_flags = (lp_posix_pathnames() ?
+ (UCF_UNIX_NAME_LOOKUP|UCF_POSIX_PATHNAMES) :
+ UCF_COND_ALLOW_WCARD_LCOMP);
+ uint32_t dst_ucf_flags = UCF_SAVE_LCOMP |
+ (lp_posix_pathnames() ? UCF_POSIX_PATHNAMES :
+ UCF_COND_ALLOW_WCARD_LCOMP);
bool stream_rename = false;
START_PROFILE(SMBmv);
bool source_has_wild = False;
bool dest_has_wild = False;
NTSTATUS status;
- uint32_t ucf_flags_src = UCF_COND_ALLOW_WCARD_LCOMP;
- uint32_t ucf_flags_dst = UCF_COND_ALLOW_WCARD_LCOMP;
+ uint32_t ucf_flags_src = UCF_COND_ALLOW_WCARD_LCOMP |
+ (lp_posix_pathnames() ? UCF_POSIX_PATHNAMES : 0);
+ uint32_t ucf_flags_dst = UCF_COND_ALLOW_WCARD_LCOMP |
+ (lp_posix_pathnames() ? UCF_POSIX_PATHNAMES : 0);
TALLOC_CTX *ctx = talloc_tos();
START_PROFILE(SMBcopy);