r9309: Incorrect null pointer check in return from talloc.
authorSteve French <sfrench@samba.org>
Mon, 15 Aug 2005 23:15:59 +0000 (23:15 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 18:33:23 +0000 (13:33 -0500)
Found by coverity.
(This used to be commit bafd3afbef9b8d3a8baa55d4b31cc62bfeeed459)

source4/libnet/domain.c

index cc5d1570f9665e38699365211e3ebd78d3bcc8bf..94a24122611490fb599dc8689fd1e4e96c400bcf 100644 (file)
@@ -177,7 +177,7 @@ struct composite_context *libnet_rpc_domain_open_send(struct dcerpc_pipe *p,
        if (c == NULL) goto failure;
 
        s = talloc_zero(c, struct domain_open_state);
-       if (c == NULL) goto failure;
+       if (s == NULL) goto failure;
 
        c->state       = SMBCLI_REQUEST_SEND;
        c->private     = s;