CustomVariables: clone vars, may not suffice

This commit is contained in:
Thomas Gelf 2015-07-31 14:46:20 +02:00
parent f4e992f6da
commit 43fc6fc42b
1 changed files with 4 additions and 1 deletions

View File

@ -174,7 +174,10 @@ class CustomVariables implements Iterator, Countable, IcingaConfigRenderer
public function setUnmodified()
{
$this->modified = false;
$this->storedVars = $this->vars;
$this->storedVars = array();
foreach ($this->vars as $key => $var) {
$this->storedVars[$key] = clone($var);
}
return $this;
}