mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-10 19:45:59 +02:00
* fixed more warnings and notes while compiling RTL.
git-svn-id: trunk@4259 -
This commit is contained in:
parent
fefe85a86a
commit
5a49addb35
@ -214,6 +214,7 @@ end;
|
||||
****************************************************************************}
|
||||
|
||||
{$IFNDEF HAS_FSPLIT}
|
||||
{$warnings off}
|
||||
Procedure FSplit (Path: PathStr; var Dir: DirStr; var Name: NameStr; var Ext: ExtStr);
|
||||
var
|
||||
DirEnd, ExtStart: Longint;
|
||||
@ -266,6 +267,7 @@ begin
|
||||
Name := Copy (Path, DirEnd + 1, ExtStart - DirEnd - 1);
|
||||
Ext := Copy (Path, ExtStart, Length (Path) - ExtStart + 1);
|
||||
end;
|
||||
{$warnings on}
|
||||
{$ENDIF HAS_FSPLIT}
|
||||
|
||||
|
||||
|
@ -126,6 +126,7 @@ begin
|
||||
|
||||
(* Allow both '/' and '\' as directory separators *)
|
||||
(* by converting all to the native one. *)
|
||||
{$warnings off}
|
||||
if DirectorySeparator = '\' then
|
||||
{Allow slash as backslash}
|
||||
begin
|
||||
@ -141,6 +142,7 @@ begin
|
||||
if Pa [I] = '\' then
|
||||
Pa [I] := '/';
|
||||
end;
|
||||
{$warnings on}
|
||||
|
||||
(* PathStart is amount of characters to strip to get beginning *)
|
||||
(* of path without volume/drive specification. *)
|
||||
|
@ -199,8 +199,10 @@ Procedure fpc_WideStr_Decr_Ref (Var S : Pointer);[Public,Alias:'FPC_WIDESTR_DECR
|
||||
}
|
||||
Type
|
||||
pSizeInt = ^SizeInt;
|
||||
{$ifndef FPC_WINLIKEWIDESTRING}
|
||||
Var
|
||||
l : pSizeInt;
|
||||
{$endif FPC_WINLIKEWIDESTRING}
|
||||
Begin
|
||||
{ Zero string }
|
||||
if S=Nil then
|
||||
@ -765,6 +767,7 @@ procedure WideCharToStrVar(S : PWideChar;out Dest : AnsiString);
|
||||
Function fpc_widestr_Unique(Var S : Pointer): Pointer; [Public,Alias : 'FPC_WIDESTR_UNIQUE']; compilerproc;
|
||||
{$ifdef FPC_WINLIKEWIDESTRING}
|
||||
begin
|
||||
pointer(result) := pointer(s);
|
||||
end;
|
||||
{$else FPC_WINLIKEWIDESTRING}
|
||||
{
|
||||
|
@ -101,7 +101,7 @@ var
|
||||
s : ansistring;
|
||||
size : dword;
|
||||
rc : dword;
|
||||
p,buf : pchar;
|
||||
buf : pchar;
|
||||
begin
|
||||
s := ExpandFileName (filename);
|
||||
|
||||
@ -852,8 +852,6 @@ Procedure LoadVersionInfo;
|
||||
// and getfreespaceex
|
||||
Var
|
||||
versioninfo : TOSVERSIONINFO;
|
||||
i : Integer;
|
||||
|
||||
begin
|
||||
kernel32dll:=0;
|
||||
GetDiskFreeSpaceEx:=nil;
|
||||
|
@ -297,8 +297,8 @@
|
||||
|
||||
_RASCONNSTATE = RASCONNSTATE;
|
||||
|
||||
RASPROJECTION = (RASP_Amb := $10000,RASP_PppNbf := $803F,RASP_PppIpx := $802B,
|
||||
RASP_PppIp := $8021);
|
||||
RASPROJECTION = (RASP_PppIp := $8021, RASP_PppIpx := $802B, RASP_PppNbf := $803F,
|
||||
RASP_Amb := $10000);
|
||||
|
||||
_RASPROJECTION = RASPROJECTION;
|
||||
|
||||
|
@ -1290,7 +1290,7 @@ end;
|
||||
|
||||
procedure FD_CLR(Socket: TSocket; var FDSet: TFDSet);
|
||||
var
|
||||
I: Longint;
|
||||
I: cardinal;
|
||||
begin
|
||||
I := 0;
|
||||
while I < FDSet.fd_count do
|
||||
|
@ -24,6 +24,8 @@ interface
|
||||
{$define Set_i386_Exception_handler}
|
||||
{$endif cpui386}
|
||||
|
||||
{$define DISABLE_NO_THREAD_MANAGER}
|
||||
|
||||
{ include system-independent routine headers }
|
||||
{$I systemh.inc}
|
||||
|
||||
@ -741,7 +743,7 @@ type
|
||||
type
|
||||
PExceptionRecord = ^TExceptionRecord;
|
||||
TExceptionRecord = packed record
|
||||
ExceptionCode : Longint;
|
||||
ExceptionCode : cardinal;
|
||||
ExceptionFlags : Longint;
|
||||
ExceptionRecord : PExceptionRecord;
|
||||
ExceptionAddress : Pointer;
|
||||
@ -851,7 +853,7 @@ begin
|
||||
if IsConsole then Writeln(stderr,'Exception ',
|
||||
hexstr(excep^.ExceptionRecord^.ExceptionCode, 8));
|
||||
{$endif SYSTEMEXCEPTIONDEBUG}
|
||||
case cardinal(excep^.ExceptionRecord^.ExceptionCode) of
|
||||
case excep^.ExceptionRecord^.ExceptionCode of
|
||||
STATUS_INTEGER_DIVIDE_BY_ZERO,
|
||||
STATUS_FLOAT_DIVIDE_BY_ZERO :
|
||||
err := 200;
|
||||
|
@ -199,8 +199,7 @@ end;
|
||||
|
||||
Function FileSeek (Handle : THandle; FOffset,Origin : Int64) : Int64;
|
||||
begin
|
||||
{$warning need to add 64bit call }
|
||||
Result := longint(SetFilePointer(Handle, longint(FOffset), nil, longint(Origin)));
|
||||
Result := SetFilePointer(Handle, longint(FOffset), nil, longint(Origin));
|
||||
end;
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user