From: bert hubert Date: Fri, 5 Jun 2015 21:00:48 +0000 (+0200) Subject: fix crash on error, plus add addDelay() to autocomplete X-Git-Tag: dnsdist-1.0.0-alpha1~248^2~78^2~19^2^2~6 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=4281178d3c5d0f0794ca58633daed1c06bce5b01;p=pdns fix crash on error, plus add addDelay() to autocomplete --- diff --git a/pdns/dnsdist.cc b/pdns/dnsdist.cc index c73620f2e..d373e7c39 100644 --- a/pdns/dnsdist.cc +++ b/pdns/dnsdist.cc @@ -888,7 +888,7 @@ char* my_generator(const char* text, int state) vector words{"showRules()", "shutdown()", "rmRule(", "mvRule(", "addACL(", "addLocal(", "setServerPolicy(", "setServerPolicyLua(", "newServer(", "rmServer(", "showServers()", "show(", "newDNSName(", "newSuffixMatchNode(", "controlSocket(", "topClients(", "showResponseLatency()", "newQPSLimiter(", "makeKey()", "setKey(", "testCrypto()", "addAnyTCRule()", "showServerPolicy()", "setACL(", "showACL()", "addDomainBlock(", - "addPoolRule(", "addQPSLimit(", "topResponses(", "topQueries(", "topRule()", "setDNSSECPool("}; + "addPoolRule(", "addQPSLimit(", "topResponses(", "topQueries(", "topRule()", "setDNSSECPool(", "addDelay("}; static int s_counter=0; int counter=0; if(!state) @@ -1142,8 +1142,10 @@ try catch(std::exception &e) { errlog("Fatal error: %s", e.what()); + _exit(EXIT_FAILURE); } catch(PDNSException &ae) { errlog("Fatal pdns error: %s", ae.reason); + _exit(EXIT_FAILURE); }