1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-23 17:34:34 +03:00

r7455: Remove some talloc contexts that aren't used.

(This used to be commit b0ad51f2ce)
This commit is contained in:
Tim Potter 2005-06-10 07:49:00 +00:00 committed by Gerald (Jerry) Carter
parent 5351ae59a0
commit 302b4db004

View File

@ -67,14 +67,10 @@ NTSTATUS smbcli_session_setup(struct smbcli_state *cli,
{ {
struct smb_composite_sesssetup setup; struct smb_composite_sesssetup setup;
NTSTATUS status; NTSTATUS status;
TALLOC_CTX *mem_ctx;
cli->session = smbcli_session_init(cli->transport, cli, True); cli->session = smbcli_session_init(cli->transport, cli, True);
if (!cli->session) return NT_STATUS_UNSUCCESSFUL; if (!cli->session) return NT_STATUS_UNSUCCESSFUL;
mem_ctx = talloc_init("smbcli_session_setup");
if (!mem_ctx) return NT_STATUS_NO_MEMORY;
setup.in.sesskey = cli->transport->negotiate.sesskey; setup.in.sesskey = cli->transport->negotiate.sesskey;
setup.in.capabilities = cli->transport->negotiate.capabilities; setup.in.capabilities = cli->transport->negotiate.capabilities;
setup.in.credentials = credentials; setup.in.credentials = credentials;
@ -84,8 +80,6 @@ NTSTATUS smbcli_session_setup(struct smbcli_state *cli,
cli->session->vuid = setup.out.vuid; cli->session->vuid = setup.out.vuid;
talloc_free(mem_ctx);
return status; return status;
} }
@ -144,9 +138,6 @@ NTSTATUS smbcli_full_connection(TALLOC_CTX *parent_ctx,
{ {
struct smbcli_tree *tree; struct smbcli_tree *tree;
NTSTATUS status; NTSTATUS status;
TALLOC_CTX *mem_ctx;
mem_ctx = talloc_init("smbcli_full_connection");
*ret_cli = NULL; *ret_cli = NULL;
@ -164,8 +155,6 @@ NTSTATUS smbcli_full_connection(TALLOC_CTX *parent_ctx,
(*ret_cli)->transport = tree->session->transport; (*ret_cli)->transport = tree->session->transport;
done: done:
talloc_free(mem_ctx);
return status; return status;
} }