CnPack Forum


 
Subject: TCnTimerMgr EIntOverflow
hsgrass
新警察
Rank: 1



UID 67271
Digest Posts 0
Credits 4
Posts 1
点点分 4
Reading Access 10
Registered 2011-11-1
Status Offline
Post at 2011-11-1 21:27  Profile | Blog | P.M. 
TCnTimerMgr EIntOverflow

Call Stack Information:
------------------------------------------------------------------------------------
|Address |Module         |Unit           |Class       |Procedure/Method   |Line    |
------------------------------------------------------------------------------------
|+Memory Leak: Type=EIntOverflow; Total size=16; Count=1                           |
|----------------------------------------------------------------------------------|
|00411B7A|VMControler.exe|sysutils.pas   |            |ErrorHandler       |13414[9]|
|00402D5A|VMControler.exe|system.pas     |            |ErrorAt            |3016[3] |
|005C71C9|VMControler.exe|CnTimer.pas    |TCnTimerMgr |WndProc            |438[3]  |
|00430354|VMControler.exe|classes.pas    |            |StdWndProc         |10966[8]|
|76C23573|user32.dll     |               |            |DispatchMessageA   |        |
|004DF754|VMControler.exe|Forms.pas      |TApplication|ProcessMessage     |6873[13]|
|004DF79B|VMControler.exe|Forms.pas      |TApplication|HandleMessage      |6892[1] |
|004DFA36|VMControler.exe|Forms.pas      |TApplication|Run                |6976[16]|


procedure TCnTimerMgr.DoTimer(Sync: Boolean);
var
  i: Integer;
  CurrTick: Int64; // 这个原来是cardinal,改为int64即可
begin
  with FTimerList.LockList do
  try
    CurrTick := timeGetTime;
    for i := 0 to Count - 1 do
      with TCnTimerObject(Items) do
        if Enabled and (FSyncEvent = Sync) and(Interval <> 0) and
          (CurrTick - FLastTickCount >= Interval) and Assigned(FOnTimer) then // 在这里升起EIntOverflow异常
        begin
          if CurrTick <> FLastTickCount then
            FActualFPS := 1000 / (CurrTick - FLastTickCount)
          else
            FActualFPS := 0;
          FLastTickCount := CurrTick;
          try
            Timer;
          except
            Application.HandleException(Self);
          end;
        end;
  finally
    FTimerList.UnlockList;
  end;
end;
Top
 




All times are GMT++8, the time now is 2024-3-29 17:14

    本论坛支付平台由支付宝提供
携手打造安全诚信的交易社区 Powered by Discuz! 5.0.0  © 2001-2006 Comsenz Inc.
Processed in 0.007141 second(s), 7 queries , Gzip enabled

Clear Cookies - Contact Us - CnPack Website - Archiver - WAP