Sfoglia il codice sorgente

* Fixed a chm reader bug that Return value was not initialized if neither binary or text index existed

git-svn-id: trunk@13955 -
andrew 16 anni fa
parent
commit
46f5d06780
1 ha cambiato i file con 1 aggiunte e 0 eliminazioni
  1. 1 0
      packages/chm/src/chmreader.pas

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

@@ -930,6 +930,7 @@ var Index   : TMemoryStream;
 function  AbortAndTryTextual:tchmsitemap;
 function  AbortAndTryTextual:tchmsitemap;
 
 
 begin
 begin
+     Result := nil;
      if Assigned(Index) Then Index.Free;
      if Assigned(Index) Then Index.Free;
      // Second Try text Index
      // Second Try text Index
      Index := GetObject(IndexFile);
      Index := GetObject(IndexFile);