From b48d6760fc5abb3f5f53bd5ee9ed7930b7562cd2 Mon Sep 17 00:00:00 2001 From: "W.C.A. Wijngaards" Date: Mon, 29 Nov 2021 15:13:14 +0100 Subject: [PATCH] - Fix #574: Review fixes for it. --- doc/Changelog | 1 + smallapp/unbound-checkconf.c | 3 +++ 2 files changed, 4 insertions(+) diff --git a/doc/Changelog b/doc/Changelog index a8b304d91..e1bbb6a7e 100644 --- a/doc/Changelog +++ b/doc/Changelog @@ -4,6 +4,7 @@ - Fix to make python module opt_list use opt_list_in. - Fix #574: unbound-checkconf reports fatal error if interface names are used as value for interfaces: + - Fix #574: Review fixes for it. 15 November 2021: Tom - Improve EDNS option handling, now also works for synthesised diff --git a/smallapp/unbound-checkconf.c b/smallapp/unbound-checkconf.c index b88d010da..7dc9994f9 100644 --- a/smallapp/unbound-checkconf.c +++ b/smallapp/unbound-checkconf.c @@ -54,6 +54,7 @@ #include "iterator/iter_hints.h" #include "validator/validator.h" #include "services/localzone.h" +#include "services/listen_dnsport.h" #include "services/view.h" #include "services/authzone.h" #include "respip/respip.h" @@ -340,7 +341,9 @@ interfacechecks(struct config_file* cfg) if(cfg->num_ifs != 0) { resif = (char***)calloc(cfg->num_ifs, sizeof(char**)); + if(!resif) fatal_exit("malloc failure"); num_resif = (int*)calloc(cfg->num_ifs, sizeof(int*)); + if(!num_resif) fatal_exit("malloc failure"); } for(i=0; inum_ifs; i++) { /* search for duplicates in IP or ifname arguments */