[icinga-checkins] icinga.org: icingaweb2/feature/redesign-7144: Fix that an error is thrown when reading INI files without trailing newlines

git at icinga.org git at icinga.org
Tue Nov 11 13:54:36 CET 2014


Module: icingaweb2
Branch: feature/redesign-7144
Commit: 268569114c452d9820679412a9932c98aee936a7
URL:    https://git.icinga.org/?p=icingaweb2.git;a=commit;h=268569114c452d9820679412a9932c98aee936a7

Author: Johannes Meyer <johannes.meyer at netways.de>
Date:   Fri Nov  7 13:38:35 2014 +0100

Fix that an error is thrown when reading INI files without trailing newlines

---

 library/Icinga/Application/Config.php |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/library/Icinga/Application/Config.php b/library/Icinga/Application/Config.php
index 568d5d7..aa3765d 100644
--- a/library/Icinga/Application/Config.php
+++ b/library/Icinga/Application/Config.php
@@ -401,7 +401,7 @@ class Config implements Countable, Iterator, ArrayAccess
             $config->setConfigFile($file);
         } elseif (is_readable($filepath)) {
             $config->setConfigFile($filepath);
-            $config->merge(parse_ini_file($filepath, true, INI_SCANNER_RAW));
+            $config->merge(parse_ini_file($filepath, true));
         } else {
             throw new NotReadableError(t('Cannot read config file "%s". Permission denied'), $filepath);
         }



More information about the icinga-checkins mailing list