diff options
Diffstat (limited to 'source3/lib')
-rw-r--r-- | source3/lib/filename_util.c | 25 |
1 files changed, 3 insertions, 22 deletions
diff --git a/source3/lib/filename_util.c b/source3/lib/filename_util.c index 2fe611c6d4..51b2d1d930 100644 --- a/source3/lib/filename_util.c +++ b/source3/lib/filename_util.c @@ -91,30 +91,11 @@ NTSTATUS create_synthetic_smb_fname_split(TALLOC_CTX *ctx, const SMB_STRUCT_STAT *psbuf, struct smb_filename **smb_fname_out) { - NTSTATUS status; - const char *stream_name = NULL; - char *base_name = NULL; - - if (!lp_posix_pathnames()) { - stream_name = strchr_m(fname, ':'); - } - - /* Setup the base_name/stream_name. */ - if (stream_name) { - base_name = talloc_strndup(ctx, fname, - PTR_DIFF(stream_name, fname)); - } else { - base_name = talloc_strdup(ctx, fname); - } - - if (!base_name) { + *smb_fname_out = synthetic_smb_fname_split(ctx, fname, psbuf); + if (*smb_fname_out == NULL) { return NT_STATUS_NO_MEMORY; } - - status = create_synthetic_smb_fname(ctx, base_name, stream_name, psbuf, - smb_fname_out); - TALLOC_FREE(base_name); - return status; + return NT_STATUS_OK; } struct smb_filename *synthetic_smb_fname_split(TALLOC_CTX *ctx, |