Răsfoiți Sursa

* Fixed dynamic array sizes

sg 26 ani în urmă
părinte
comite
a56684bb8a
1 a modificat fișierele cu 7 adăugiri și 4 ștergeri
  1. 7 4
      fcl/inc/gettext.pp

+ 7 - 4
fcl/inc/gettext.pp

@@ -43,14 +43,14 @@ type
     offset: LongWord;
     offset: LongWord;
   end;
   end;
 
 
-  TMOStringTable = array[LongWord] of TMOStringInfo;
+  TMOStringTable = array[0..(1 shl 30) div SizeOf(TMOStringInfo)] of TMOStringInfo;
   PMOStringTable = ^TMOStringTable;
   PMOStringTable = ^TMOStringTable;
 
 
 
 
-  TLongWordArray = array[LongWord] of LongWord;
+  TLongWordArray = array[0..(1 shl 30) div SizeOf(LongWord)] of LongWord;
   PLongWordArray = ^TLongWordArray;
   PLongWordArray = ^TLongWordArray;
 
 
-  TPCharArray = array[LongWord] of PChar;
+  TPCharArray = array[0..(1 shl 30) div SizeOf(PChar)] of PChar;
   PPCharArray = ^TPCharArray;
   PPCharArray = ^TPCharArray;
 
 
   TMOFile = class
   TMOFile = class
@@ -271,7 +271,10 @@ end.
 
 
 {
 {
   $Log$
   $Log$
-  Revision 1.10  2000-02-17 22:14:51  sg
+  Revision 1.11  2000-02-20 10:59:11  sg
+  * Fixed dynamic array sizes
+
+  Revision 1.10  2000/02/17 22:14:51  sg
   * Now calls "ResetResourceTables" on unit finalization if gettext has been
   * Now calls "ResetResourceTables" on unit finalization if gettext has been
     used. This enabled programs using gettext to use heaptrc, which reported
     used. This enabled programs using gettext to use heaptrc, which reported
     memory leaks for the translated strings until now.
     memory leaks for the translated strings until now.