mirror of https://github.com/Icinga/icinga2.git
ad218c9a12
IcingaDB may receive callbacks from Boost signals before being fully started. This resulted in situations where m_EnvironmentId was used before it was initialized properly. This is fixed by initializing it earlier (during the config validation stage). However, at this stage, it should not yet write to disk, therefore, persisting the environment ID to disk is delayed until later in the startup process. Initializing at this stage has an extra benefit: if there is an error for some reason (possibly corrupt icingadb.env file), this now shows up as a nice error during config validation. Additionally, this replaces the use of std::call_once with std::mutex due to bug in libstdc++ (see inline comment for reference). |
||
---|---|---|
.. | ||
base | ||
checker | ||
cli | ||
compat | ||
config | ||
db_ido | ||
db_ido_mysql | ||
db_ido_pgsql | ||
icinga | ||
icingadb | ||
livestatus | ||
methods | ||
mysql_shim | ||
notification | ||
perfdata | ||
pgsql_shim | ||
remote | ||
CMakeLists.txt |