Browse Source

* Fix range check errors

git-svn-id: trunk@45387 -
michael 5 years ago
parent
commit
03f2c69d0d
1 changed files with 2 additions and 2 deletions
  1. 2 2
      packages/rtl-extra/src/inc/sockets.inc

+ 2 - 2
packages/rtl-extra/src/inc/sockets.inc

@@ -398,7 +398,7 @@ end;
 
 const digittab : shortstring = ('0123456789ABCDEF');
 
-function lclinttohex (i:integer;digits:longint): ansistring;
+function lclinttohex (i:longint;digits:longint): ansistring;
 
 begin
   SetLength(lclinttohex,4);
@@ -734,7 +734,7 @@ begin
     // NOTE: optimization note: memmove/memcpy equivalent could help here.
     if hextet_idx < 8 then exit;
     for tmpByte := 0 to 7 do
-      ip6.s6_addr16[tmpByte] := hextet_arr[tmpByte];
+      ip6.u6_addr16[tmpByte] := hextet_arr[tmpByte];
   end;
   TryStrToHostAddr6 := True;
 end;