From: Frederic Marchal Date: Sun, 4 Oct 2015 14:11:05 +0000 (+0200) Subject: Always display a message when exiting on a failure. X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=ad278b5900aa808b6992fd3561d216cb41c5ee0c;p=thirdparty%2Fsarg.git Always display a message when exiting on a failure. --- diff --git a/btree_cache.c b/btree_cache.c index 18d2007..4bc1091 100644 --- a/btree_cache.c +++ b/btree_cache.c @@ -258,6 +258,7 @@ void balance_node(struct bt *node) rotate_left(node); break; default: + debuga(__FILE__,__LINE__,_("Failed to balance the b-tree cache")); exit(EXIT_FAILURE); break; diff --git a/filelist.c b/filelist.c index c36b96d..d439564 100644 --- a/filelist.c +++ b/filelist.c @@ -456,6 +456,9 @@ const char *FileListIter_Next(struct _FileListIterator *FIter) case GLOB_NOMATCH: debuga(__FILE__,__LINE__,_("No files matching \"%s\"\n"),Path); break; + default: + debuga(__FILE__,__LINE__,_("Failed to glob file pattern \"%s\" with unspecified error code %d"),Path,ErrCode); + break; } exit(EXIT_FAILURE); } diff --git a/ip2name.c b/ip2name.c index d30f3f7..75a949c 100644 --- a/ip2name.c +++ b/ip2name.c @@ -186,7 +186,7 @@ void ip2name_forcedns(void) } } if (!DnsModule) { - if (debugz>=LogLevel_Process) debuga(__FILE__,__LINE__,_("No known module to resolve an IP address using the DNS\n")); + debuga(__FILE__,__LINE__,_("No known module to resolve an IP address using the DNS\n")); exit(EXIT_FAILURE); }