* finally (hopefully) fixed sysalloc trouble

This commit is contained in:
florian 2004-06-27 11:57:18 +00:00
parent 0f03982456
commit 8f6f6bfc30
2 changed files with 9 additions and 7 deletions

View File

@ -1104,7 +1104,7 @@ function SysAllocMem(size: ptrint): pointer;
begin
sysallocmem := MemoryManager.GetMem(size);
if sysallocmem<>nil then
FillChar(sysallocmem^,size,0);
FillChar(sysallocmem^,MemoryManager.MemSize(sysallocmem),0);
end;
@ -1286,7 +1286,10 @@ end;
{
$Log$
Revision 1.32 2004-06-18 14:40:55 peter
Revision 1.33 2004-06-27 11:57:18 florian
* finally (hopefully) fixed sysalloc trouble
Revision 1.32 2004/06/18 14:40:55 peter
* moved padding for sparc
Revision 1.31 2004/06/17 16:16:13 peter

View File

@ -731,15 +731,11 @@ var
argvlen : longint;
procedure allocarg(idx,len:longint);
var
oldargvlen : longint;
begin
oldargvlen:=argvlen;
if idx>=argvlen then
begin
argvlen:=(idx+8) and (not 7);
sysreallocmem(argv,argvlen*sizeof(pointer));
fillchar(argv[oldargvlen],(argvlen-oldargvlen)*sizeof(pointer),0);
end;
{ use realloc to reuse already existing memory }
{ always allocate, even if length is zero, since }
@ -1625,7 +1621,10 @@ end.
{
$Log$
Revision 1.59 2004-06-26 15:05:14 florian
Revision 1.60 2004-06-27 11:57:18 florian
* finally (hopefully) fixed sysalloc trouble
Revision 1.59 2004/06/26 15:05:14 florian
* fixed argument copying
Revision 1.58 2004/06/20 09:24:40 peter