[svn] commit: r1318 - /trunk/src/bin/auth/auth_srv.cc
BIND 10 source code commits
bind10-changes at lists.isc.org
Thu Mar 11 03:29:35 UTC 2010
Author: each
Date: Thu Mar 11 03:29:35 2010
New Revision: 1318
Log:
Return SERVFAIL if an exception is encountered during doQuery().
This is very preliminary; it should also log (at least to cerr)
the exception that occurred, and should clear the message sections
of any data they may have contained before the exception was thrown.
Modified:
trunk/src/bin/auth/auth_srv.cc
Modified: trunk/src/bin/auth/auth_srv.cc
==============================================================================
--- trunk/src/bin/auth/auth_srv.cc (original)
+++ trunk/src/bin/auth/auth_srv.cc Thu Mar 11 03:29:35 2010
@@ -150,8 +150,12 @@
message.setDNSSECSupported(dnssec_ok);
message.setUDPSize(4096); // XXX: hardcoding
- Query query(message, dnssec_ok);
- impl_->data_sources_.doQuery(query);
+ try {
+ Query query(message, dnssec_ok);
+ impl_->data_sources_.doQuery(query);
+ } catch(...) {
+ message.setRcode(Rcode::SERVFAIL());
+ }
response_renderer.setLengthLimit(udp_buffer ? remote_bufsize : 65535);
message.toWire(response_renderer);
More information about the bind10-changes
mailing list