diff --git a/plugins-root/check_icmp.c b/plugins-root/check_icmp.c index 274277b7..197ce32f 100644 --- a/plugins-root/check_icmp.c +++ b/plugins-root/check_icmp.c @@ -758,6 +758,10 @@ main(int argc, char **argv) host = list; table = malloc(sizeof(struct rta_host *) * targets); + if(!table) { + crash("main(): malloc failed for host table"); + return 3; + } i = 0; while(host) {