Pārlūkot izejas kodu

* fix for case that none of the two indexes are present.

git-svn-id: trunk@13844 -
marco 16 gadi atpakaļ
vecāks
revīzija
49aacb4a24
1 mainītis faili ar 3 papildinājumiem un 1 dzēšanām
  1. 3 1
      packages/chm/src/chmreader.pas

+ 3 - 1
packages/chm/src/chmreader.pas

@@ -938,7 +938,9 @@ begin
        Result := TChmSiteMap.Create(stIndex);
        Result.LoadFromStream(Index);
        Index.Free;
-     end;
+     end
+    else
+      result:=nil;
 end;
 
 procedure createentry(Name:ansistring;CharIndex:integer;Topic,Title:ansistring);