Browse Source

* ifdef ENDIAN_BIG instead of ifdef ENDIAN_LITTLE, so non endian aware
compilers (usually x86) get the little endian code.

git-svn-id: trunk@4568 -

daniel 19 years ago
parent
commit
f83baab54f
1 changed files with 7 additions and 7 deletions
  1. 7 7
      packages/base/paszlib/gzio.pas

+ 7 - 7
packages/base/paszlib/gzio.pas

@@ -362,18 +362,18 @@ var
   c : integer;
   c : integer;
 begin
 begin
   { x := cardinal(get_byte(s));  - you can't do this with TP, no unsigned longint }
   { x := cardinal(get_byte(s));  - you can't do this with TP, no unsigned longint }
-{$ifdef ENDIAN_LITTLE}
-  x[0] := Byte(get_byte(s));
-  x[1] := Byte(get_byte(s));
-  x[2] := Byte(get_byte(s));
-  c := get_byte(s);
-  x[3] := Byte(c);
-{$else}
+{$ifdef ENDIAN_BIG}
   x[3] := Byte(get_byte(s));
   x[3] := Byte(get_byte(s));
   x[2] := Byte(get_byte(s));
   x[2] := Byte(get_byte(s));
   x[1] := Byte(get_byte(s));
   x[1] := Byte(get_byte(s));
   c := get_byte(s);
   c := get_byte(s);
   x[0] := Byte(c);
   x[0] := Byte(c);
+{$else}
+  x[0] := Byte(get_byte(s));
+  x[1] := Byte(get_byte(s));
+  x[2] := Byte(get_byte(s));
+  c := get_byte(s);
+  x[3] := Byte(c);
 {$endif}
 {$endif}
   if (c = Z_EOF) then
   if (c = Z_EOF) then
     s^.z_err := Z_DATA_ERROR;
     s^.z_err := Z_DATA_ERROR;