From bd45266f7403c422cf850806cd69871a1600b3d3 Mon Sep 17 00:00:00 2001 From: Sami Kerola Date: Fri, 4 Dec 2015 20:38:16 +0000 Subject: [PATCH] drop a core when bug condition happens Having a core will help enormously debugging these issues. Signed-off-by: Sami Kerola --- src/getdata.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/getdata.c b/src/getdata.c index ba43cbe..03a0b13 100644 --- a/src/getdata.c +++ b/src/getdata.c @@ -40,7 +40,6 @@ #include #include -#include #include #include #include @@ -246,7 +245,8 @@ void parse_config(int is_include, const char *restrict config_file, break; } else if (argument == ITS_A_RANGE_SECOND_IP && i == 0) { if (!range_p) { - error(EXIT_FAILURE, 0, "parse_config: range_p uninitialized: please report a bug"); + puts("parse_config: range_p uninitialized: report a bug"); + abort(); } range_p->last_ip = range_p->first_ip; goto newrange; @@ -384,8 +384,8 @@ void parse_config(int is_include, const char *restrict config_file, argument = ITS_NOTHING_INTERESTING; break; default: - error(0, 0, "impossible occurred, report a bug"); - assert(0); + puts("impossible occurred, report a bug"); + abort(); } } }