[fpc-pascal] Java crash when fpc library CallVoidMethod in a thread.
Ewald
ewald at yellowcouch.org
Thu May 29 12:14:19 CEST 2014
On 05/29/2014 11:18 AM, fredvs wrote:
> but the timer does not execute
> CallvoidMethod at fptimer.ontimer...
Just a guess here...
To quote Sven a few mails ago: `CheckSynchronize is used to process
calls to TThread.Synchronize and TThread.Queue. It *must* be called in
the context of the main thread (the thread that loaded the library).
TFPTimer uses Synchronize internally, [...]`
But you didn't use the word `CheckSynchronize` anywhere in your mail.
You need to call this method regularly in you main thread, if you don't
call it, nothing will happen; you only fill up the queue that
CheckSynchronize is supposed to empty. See
http://www.freepascal.org/docs-html/rtl/classes/checksynchronize.html
for more details on this call.
--
Ewald
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20140529/b4e29d84/attachment.html>
More information about the fpc-pascal
mailing list