Skip to content
This repository has been archived by the owner on Oct 6, 2023. It is now read-only.

Commit

Permalink
fix(cv): c++11 does not allow us to erase during a foreach...
Browse files Browse the repository at this point in the history
fix(chore): bump version and add release_notes
enh(core): update release notes
  • Loading branch information
SylvestreG committed Nov 4, 2019
1 parent 1eb91bf commit 427802c
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 4 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ include_directories("${INC_DIR}/compatibility")
# Version.
set(CENTREON_ENGINE_MAJOR 19)
set(CENTREON_ENGINE_MINOR 10)
set(CENTREON_ENGINE_PATCH 3)
set(CENTREON_ENGINE_PATCH 4)
if (CENTREON_ENGINE_PRERELEASE)
set(CENTREON_ENGINE_VERSION "${CENTREON_ENGINE_MAJOR}.${CENTREON_ENGINE_MINOR}.${CENTREON_ENGINE_PATCH}-${CENTREON_ENGINE_PRERELEASE}")
else ()
Expand Down
20 changes: 20 additions & 0 deletions doc/release_notes/engine19.10.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,23 @@
=======================
Centreon Engine 19.10.4
=======================

*********
Bug fixes
*********

Custom variable update crash on reload
======================================
A bug was introduce in 19.10.2 with a reload on custom_variables
services/contacts/hosts update.

Recovery notification didn't work on escalation [1;0]
=====================================================
If an escalation was defined with a first notification at 1 and a
last notification at 0, we want the escalation to start from the
first notification, but only one time, the recovery notification
was not sent.

=======================
Centreon Engine 19.10.3
=======================
Expand Down
2 changes: 1 addition & 1 deletion src/configuration/applier/contact.cc
Original file line number Diff line number Diff line change
Expand Up @@ -351,8 +351,8 @@ void applier::contact::modify_object(configuration::contact const& obj) {
cus.first.c_str(), cus.second.get_value().c_str(),
&tv);
}
c->get_custom_variables().erase(cus.first);
}
c->get_custom_variables().clear();

for (auto& cus: obj.customvariables()) {
c->get_custom_variables()[cus.first] = cus.second;
Expand Down
2 changes: 1 addition & 1 deletion src/configuration/applier/host.cc
Original file line number Diff line number Diff line change
Expand Up @@ -392,8 +392,8 @@ void applier::host::modify_object(
c.first.c_str(), c.second.get_value().c_str(),
&tv);
}
it_obj->second->custom_variables.erase(c.first);
}
it_obj->second->custom_variables.clear();

for (auto& c: obj.customvariables()) {
it_obj->second->custom_variables[c.first] = c.second;
Expand Down
2 changes: 1 addition & 1 deletion src/configuration/applier/service.cc
Original file line number Diff line number Diff line change
Expand Up @@ -485,8 +485,8 @@ void applier::service::modify_object(
NEBTYPE_SERVICECUSTOMVARIABLE_DELETE, NEBFLAG_NONE, NEBATTR_NONE,
s.get(), c.first.c_str(), c.second.get_value().c_str(), &tv);
}
s->custom_variables.erase(c.first);
}
s->custom_variables.clear();

for (auto& c: obj.customvariables()) {
s->custom_variables[c.first] = c.second;
Expand Down

0 comments on commit 427802c

Please sign in to comment.