On Jan 19, 2008, at 2:07 PM, Mark Morgan Lloyd wrote:

Damien Gerard wrote:

 n := FTimerData.Count;
 while (n>0) do begin
   dec(n);

> It seems FTimerData is not properly set. Is it possible ? May be it is > related to some bad behavior of my application (I really don't know what
> but it is not impossible)

Try explicitly disabling this while the loop is running in case it's going reentrant.

In fact I have problems once I use Threads in my application under Windows (works perfectly under Linux).

Is this relevant? Is the code you've quoted being run by a non-main thread or trying to share something?

I've got a program here using multiple threads on Windows, linux/386 and linux/sparc. Obviously all user interaction is handled by the main thread, various UDP etc. is running in the background.


When I use TTimer instead of my own Thread it works under Windows ... :(
May be you are right. It must have multiple interaction with the gui.

--
Damien Gerard
[EMAIL PROTECTED]

Le temps n'a pas d'importance. Seul le code est important
   -- (f00ty)




_________________________________________________________________
    To unsubscribe: mail [EMAIL PROTECTED] with
               "unsubscribe" as the Subject
  archives at http://www.lazarus.freepascal.org/mailarchives

Reply via email to