gqueue unit memory access error
Original Reporter info from Mantis: fpctuxe
-
Reporter name: Thomas Bulla
Original Reporter info from Mantis: fpctuxe
- Reporter name: Thomas Bulla
Description:
Hello,
the gqueue unit make problems. If I take a big queue it takes memory access error. I think it is in the IncreaseCapacity routine. I have build a little program to demonstrate the problem.
Additional information:
program gqueue_test;
uses
gqueue;
type
TIntQueue = specialize TQueue<Integer>;
var
IntQueue: TIntQueue;
PushCnt: Integer;
procedure Push2Pop1;
var
i: Integer;
begin
for i:= 0 to 1000000 do begin
IntQueue.Push(PushCnt);
inc(PushCnt);
IntQueue.Push(PushCnt);
inc(PushCnt);
IntQueue.Pop();
end;
end;
var
i: Integer;
begin
try
IntQueue:= TIntQueue.Create;
Push2Pop1;
WriteLn('Ready');
ReadLn;
finally
IntQueue.Free;
end;
end.
Mantis conversion info:
- Mantis ID: 38306
- Version: 3.2.0
- Fixed in version: 3.3.1
- Fixed in revision: 48405 (#bdd04961)
- Monitored by: » fpctuxe (Thomas Bulla)