]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
rpcclient: talloc_stackframe() panics on failure
authorVolker Lendecke <vl@samba.org>
Sat, 6 Feb 2021 14:56:52 +0000 (15:56 +0100)
committerJeremy Allison <jra@samba.org>
Tue, 9 Mar 2021 22:36:28 +0000 (22:36 +0000)
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/rpcclient/rpcclient.c

index a38f69f55927cf9fd28ab78eaf6fbdada712d1cc..e2a9aa97c32d34badc34ae9eb97629b4a5bbf95e 100644 (file)
@@ -783,14 +783,7 @@ static NTSTATUS do_cmd(struct cli_state *cli,
        NTSTATUS ntresult;
        WERROR wresult;
 
-       TALLOC_CTX *mem_ctx;
-
-       /* Create mem_ctx */
-
-       if (!(mem_ctx = talloc_stackframe())) {
-               DEBUG(0, ("talloc_init() failed\n"));
-               return NT_STATUS_NO_MEMORY;
-       }
+       TALLOC_CTX *mem_ctx = talloc_stackframe();
 
        /* Open pipe */