Bladeren bron

amicommon/dos: some warning fixes - use PtrInt instead of LongInt; do not check for less than zero values in unsigned variables

git-svn-id: trunk@31173 -
Károly Balogh 10 jaren geleden
bovenliggende
commit
51a6c217c7
1 gewijzigde bestanden met toevoegingen van 4 en 4 verwijderingen
  1. 4 4
      rtl/amicommon/dos.pp

+ 4 - 4
rtl/amicommon/dos.pp

@@ -109,7 +109,7 @@ begin
   dosLock:=Lock(buffer,accessmode);
 end;
 
-function BADDR(bval: LongInt): Pointer; Inline;
+function BADDR(bval: PtrInt): Pointer; Inline;
 begin
   {$if defined(AROS) and (not defined(AROS_FLAVOUR_BINCOMPAT))}
   BADDR := Pointer(bval);
@@ -127,7 +127,7 @@ begin
   {$endif}
 end;
 
-function BSTR2STRING(s : LongInt): PChar; Inline;
+function BSTR2STRING(s : PtrInt): PChar; Inline;
 begin
   {$if defined(AROS) and (not defined(AROS_FLAVOUR_BINCOMPAT))}
   BSTR2STRING:=PChar(s);
@@ -670,7 +670,7 @@ end;
 function DiskSize(Drive: Byte): Int64;
 begin
   DiskSize := -1;
-  if (Drive < 0) or (Drive >= NumDevices) then
+  if (Drive >= NumDevices) then
     Exit;
   DiskSize := DiskSize(DeviceList[Drive]);
 end;
@@ -700,7 +700,7 @@ end;
 function DiskFree(Drive: Byte): Int64;
 begin
   DiskFree := -1;
-  if (Drive < 0) or (Drive >= NumDevices) then
+  if (Drive >= NumDevices) then
     Exit;
   DiskFree := DiskFree(DeviceList[Drive]);
 end;