BIND 10 trac2439, updated. a55716a04087917db71ff5b224b922d05ec6d6c6 [2439] Refactor: unify common code
BIND 10 source code commits
bind10-changes at lists.isc.org
Tue Jan 22 10:32:59 UTC 2013
The branch, trac2439 has been updated
via a55716a04087917db71ff5b224b922d05ec6d6c6 (commit)
from 2cbabde53f226cb4fa4883b9578268719f28732b (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit a55716a04087917db71ff5b224b922d05ec6d6c6
Author: Michal 'vorner' Vaner <michal.vaner at nic.cz>
Date: Tue Jan 22 11:32:10 2013 +0100
[2439] Refactor: unify common code
There'll be more of this code soon, to check the zone data.
-----------------------------------------------------------------------
Summary of changes:
src/bin/xfrin/xfrin.py.in | 14 ++++++++++----
1 file changed, 10 insertions(+), 4 deletions(-)
-----------------------------------------------------------------------
diff --git a/src/bin/xfrin/xfrin.py.in b/src/bin/xfrin/xfrin.py.in
index da0f207..2ea6253 100755
--- a/src/bin/xfrin/xfrin.py.in
+++ b/src/bin/xfrin/xfrin.py.in
@@ -429,8 +429,7 @@ class XfrinIXFRAdd(XfrinState):
if soa_serial == conn._end_serial:
# The final part is there. Check all was signed
# and commit it to the database.
- conn._check_response_tsig_last()
- conn._diff.commit()
+ conn._finish_transfer()
self.set_xfrstate(conn, XfrinIXFREnd())
return True
elif soa_serial != conn._current_serial:
@@ -507,8 +506,7 @@ class XfrinAXFREnd(XfrinState):
indicating there will be no more message to receive.
"""
- conn._check_response_tsig_last()
- conn._diff.commit()
+ conn._finish_transfer()
return False
class XfrinTransferStats:
@@ -805,6 +803,14 @@ class XfrinConnection(asyncore.dispatcher):
raise XfrinProtocolError('TSIG verify fail: no TSIG on last '+
'message')
+ def _finish_transfer(self):
+ """
+ Perform any necessary checks after a transfer. Then complete the
+ transfer by commiting the transaction into the data source.
+ """
+ self._check_response_tsig_last()
+ self._diff.commit()
+
def __parse_soa_response(self, msg, response_data):
'''Parse a response to SOA query and extract the SOA from answer.
More information about the bind10-changes
mailing list