浏览代码

Bug fix: Configuration reading was broken after an attempt to access a non-existing sub-section within a section existed in raw configuration only

Source commit: 2c62787d00b360c9720f3753917544666861df30
Martin Prikryl 2 年之前
父节点
当前提交
46cacc3db3
共有 1 个文件被更改,包括 4 次插入1 次删除
  1. 4 1
      source/core/HierarchicalStorage.cpp

+ 4 - 1
source/core/HierarchicalStorage.cpp

@@ -1186,7 +1186,10 @@ bool __fastcall TCustomIniFileStorage::OpenSubKey(const UnicodeString & Key, boo
   {
     if (FMasterStorageOpenFailures > 0)
     {
-      FMasterStorageOpenFailures++;
+      if (Result)
+      {
+        FMasterStorageOpenFailures++;
+      }
     }
     else
     {