Created
April 26, 2013 11:45
-
-
Save Habbie/5466833 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Index: pdns/dnsbackend.cc | |
=================================================================== | |
--- pdns/dnsbackend.cc (revision 2983) | |
+++ pdns/dnsbackend.cc (working copy) | |
@@ -182,7 +182,13 @@ | |
ret.push_back(made); | |
} | |
} | |
- catch(...) { | |
+ catch(AhuException &ae) { | |
+ L<<Logger::Error<<"Caught an exception instantiating a backend: "<<ae.reason<<endl; | |
+ L<<Logger::Error<<"Cleaning up"<<endl; | |
+ for(vector<DNSBackend *>::const_iterator i=ret.begin();i!=ret.end();++i) | |
+ delete *i; | |
+ throw; | |
+ } catch(...) { | |
// and cleanup | |
L<<Logger::Error<<"Caught an exception instantiating a backend, cleaning up"<<endl; | |
for(vector<DNSBackend *>::const_iterator i=ret.begin();i!=ret.end();++i) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment