LOG_INFO(dhcp6_logger, DHCP6_SHUTDOWN);
+ // Avoid a static destruction order fiasco with secure DHCPv6
+ // and Botan crypto backend...
+ CfgMgr::instance().clear(false);
+
} catch (const std::exception& ex) {
// First, we print the error on stderr (that should always work)
// the logger subsystem)
LOG_FATAL(dhcp6_logger, DHCP6_SERVER_FAILED).arg(ex.what());
ret = EXIT_FAILURE;
+
+ // No finally in C++?
+ CfgMgr::instance().clear(false);
}
return (ret);
///
/// This function removes all configurations, including current and
/// staging configurations. It creates a new current configuration with
- /// default settings.
+ /// default settings when @param reinit is true.
///
/// This function is exception safe.
- void clear();
+ void clear(bool reinit = true);
/// @brief Commits the staging configuration.
///