]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s4/dnsserver: Fix NULL check
authorJoseph Sutton <josephsutton@catalyst.net.nz>
Thu, 2 Sep 2021 05:14:44 +0000 (17:14 +1200)
committerJeremy Allison <jra@samba.org>
Sat, 4 Sep 2021 00:10:37 +0000 (00:10 +0000)
Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source4/dns_server/dnsserver_common.c

index 984c65dbdf80e7dfd89c734f561afbc58cdf7f97..71aeee8169dc0264065b1052e29292b651df900d 100644 (file)
@@ -283,7 +283,7 @@ static struct ldb_parse_tree *build_equality_operation(
        value = &el->u.equality.value;
        length = (add_asterix) ? size + 2 : size + 1;
        value->data = talloc_zero_array(el, uint8_t, length);
-       if (el == NULL) {
+       if (value->data == NULL) {
                DBG_ERR("Unable to allocate value->data\n");
                TALLOC_FREE(el);
                return NULL;