mirror of
https://github.com/samba-team/samba.git
synced 2025-02-04 17:47:26 +03:00
s3: smbd: In dfs_filename_convert(), don't ask for hostname, sharename and then just free them.
Wastes a talloc/free. Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Ralph Boehme <slow@samba.org>
This commit is contained in:
parent
06750a9684
commit
b6afd481a4
@ -1128,8 +1128,6 @@ NTSTATUS dfs_filename_convert(TALLOC_CTX *ctx,
|
|||||||
const char *dfs_path_in,
|
const char *dfs_path_in,
|
||||||
char **pp_path_out)
|
char **pp_path_out)
|
||||||
{
|
{
|
||||||
char *hostname = NULL;
|
|
||||||
char *servicename = NULL;
|
|
||||||
char *reqpath = NULL;
|
char *reqpath = NULL;
|
||||||
NTSTATUS status;
|
NTSTATUS status;
|
||||||
|
|
||||||
@ -1137,20 +1135,13 @@ NTSTATUS dfs_filename_convert(TALLOC_CTX *ctx,
|
|||||||
conn,
|
conn,
|
||||||
dfs_path_in,
|
dfs_path_in,
|
||||||
!conn->sconn->using_smb2,
|
!conn->sconn->using_smb2,
|
||||||
&hostname,
|
NULL, /* hostname */
|
||||||
&servicename,
|
NULL, /* servicename */
|
||||||
&reqpath);
|
&reqpath);
|
||||||
if (!NT_STATUS_IS_OK(status)) {
|
if (!NT_STATUS_IS_OK(status)) {
|
||||||
return status;
|
return status;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
|
||||||
* Caller doesn't care about hostname
|
|
||||||
* or servicename.
|
|
||||||
*/
|
|
||||||
TALLOC_FREE(hostname);
|
|
||||||
TALLOC_FREE(servicename);
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* If parse_dfs_path fell back to a local path
|
* If parse_dfs_path fell back to a local path
|
||||||
* after skipping hostname or servicename, ensure
|
* after skipping hostname or servicename, ensure
|
||||||
|
Loading…
x
Reference in New Issue
Block a user