[svn] commit: r568 - /branches/parkinglot/src/lib/config/python/isc/config/CCSession.py
BIND 10 source code commits
bind10-changes at lists.isc.org
Wed Jan 27 20:05:52 UTC 2010
Author: jelte
Date: Wed Jan 27 20:05:51 2010
New Revision: 568
Log:
a bit of checks on get_config answer
Modified:
branches/parkinglot/src/lib/config/python/isc/config/CCSession.py
Modified: branches/parkinglot/src/lib/config/python/isc/config/CCSession.py
==============================================================================
--- branches/parkinglot/src/lib/config/python/isc/config/CCSession.py (original)
+++ branches/parkinglot/src/lib/config/python/isc/config/CCSession.py Wed Jan 27 20:05:51 2010
@@ -82,6 +82,11 @@
"""Asks the configuration manager for the current configuration, and call the config handler if set"""
self._session.group_sendmsg({ "command": [ "get_config", { "module_name": self._module_name } ] }, "ConfigManager")
answer, env = self._session.group_recvmsg(False)
- if self._config_handler:
- self._config_handler(answer["result"])
+ if "result" in answer:
+ if answer["result"][0] == 0 and len(answer["result"]) > 1:
+ new_config = answer["result"][1]
+ if self._data_definition.validate(new_config):
+ self._config = new_config;
+ if self._config_handler:
+ self._config_handler(answer["result"])
More information about the bind10-changes
mailing list