Browse Source

[5186] Made timer unregistration conditional (seems to be enough)

Francis Dupont 8 years ago
parent
commit
ca2130c386
1 changed files with 3 additions and 1 deletions
  1. 3 1
      src/bin/dhcp4/json_config_parser.cc

+ 3 - 1
src/bin/dhcp4/json_config_parser.cc

@@ -413,7 +413,9 @@ configureDhcp4Server(Dhcpv4Srv&, isc::data::ConstElementPtr config_set,
     Subnet::resetSubnetID();
 
     // Remove any existing timers.
-    TimerMgr::instance()->unregisterTimers();
+    if (!check_only) {
+        TimerMgr::instance()->unregisterTimers();
+    }
 
     // Revert any runtime option definitions configured so far and not committed.
     LibDHCP::revertRuntimeOptionDefs();