mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-18 00:09:23 +02:00
+ Added windows msvcrt support
This commit is contained in:
parent
38c6da0933
commit
c9f2e8007f
@ -20,11 +20,18 @@ unit cmem;
|
|||||||
|
|
||||||
interface
|
interface
|
||||||
|
|
||||||
Function Malloc (Size : Longint) : Pointer;cdecl; external 'c' name 'malloc';
|
Const
|
||||||
Procedure Free (P : pointer); cdecl; external 'c' name 'free';
|
{$ifndef win32}
|
||||||
Procedure FreeMem (P : Pointer); cdecl; external 'c' name 'free';
|
LibName = 'c';
|
||||||
function ReAlloc (P : Pointer; Size : longint) : pointer; cdecl; external 'c' name 'realloc';
|
{$else}
|
||||||
Function CAlloc (unitSize,UnitCount : Longint) : pointer;cdecl;external 'c' name 'calloc';
|
LibName = 'msvcrt';
|
||||||
|
{$endif}
|
||||||
|
|
||||||
|
Function Malloc (Size : Longint) : Pointer; {$ifndef win32}stdcall{$else}cdecl{$endif}; external LibName name 'malloc';
|
||||||
|
Procedure Free (P : pointer); {$ifndef win32}stdcall{$else}cdecl{$endif}; external LibName name 'free';
|
||||||
|
Procedure FreeMem (P : Pointer); {$ifndef win32}stdcall{$else}cdecl{$endif}; external LibName name 'free';
|
||||||
|
function ReAlloc (P : Pointer; Size : longint) : pointer; {$ifndef win32}stdcall{$else}cdecl{$endif}; external LibName name 'realloc';
|
||||||
|
Function CAlloc (unitSize,UnitCount : Longint) : pointer; {$ifndef win32}stdcall{$else}cdecl{$endif}; external LibName name 'calloc';
|
||||||
|
|
||||||
implementation
|
implementation
|
||||||
|
|
||||||
@ -112,7 +119,10 @@ end.
|
|||||||
|
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.2 2002-06-13 04:54:47 michael
|
Revision 1.3 2002-06-13 05:01:44 michael
|
||||||
|
+ Added windows msvcrt support
|
||||||
|
|
||||||
|
Revision 1.2 2002/06/13 04:54:47 michael
|
||||||
+ Fixed parameter type mismatch
|
+ Fixed parameter type mismatch
|
||||||
|
|
||||||
Revision 1.1 2002/01/29 17:54:59 peter
|
Revision 1.1 2002/01/29 17:54:59 peter
|
||||||
|
Loading…
Reference in New Issue
Block a user