From 359c89cc1f23d49a718b96905c698f59f0cc474c Mon Sep 17 00:00:00 2001 From: Petr Ledvina Date: Tue, 18 Oct 2022 13:45:18 +0200 Subject: [PATCH] Inconsistent comments in INI files There is minor inconsistency with comment handling in INI file: ``` dir1 = "I have commentsPost(c1)" ; c1 dir2 = I have no comments ; c2 dir3 = I have commentsPre(c2) from previous line ``` --- library/Icinga/File/Ini/IniParser.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/Icinga/File/Ini/IniParser.php b/library/Icinga/File/Ini/IniParser.php index 279aa45260..6a8b52b6af 100644 --- a/library/Icinga/File/Ini/IniParser.php +++ b/library/Icinga/File/Ini/IniParser.php @@ -153,7 +153,7 @@ public static function parseIni($str) $state = self::LINE_START; $line ++; } elseif ($s === ';') { - $state = self::COMMENT; + $state = self::COMMENT_END; } } else { $token .= $s;