]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Add DBC checks to named_checknames_get
authorMark Andrews <marka@isc.org>
Wed, 20 May 2020 01:56:37 +0000 (11:56 +1000)
committerMark Andrews <marka@isc.org>
Mon, 25 May 2020 01:09:56 +0000 (11:09 +1000)
bin/named/config.c

index b452262ee1e1a23ef8acd4a8cf5a22577e7e6e47..121ddd1c128b8211ff816d590b97f8856b81d176 100644 (file)
@@ -352,6 +352,10 @@ named_checknames_get(const cfg_obj_t **maps, const char *which,
        const cfg_obj_t *value;
        int i;
 
+       REQUIRE(maps != NULL);
+       REQUIRE(which != NULL);
+       REQUIRE(obj != NULL && *obj == NULL);
+
        for (i = 0;; i++) {
                if (maps[i] == NULL) {
                        return (ISC_R_NOTFOUND);