[fpc-pascal] lnet for TCP daemon

Marco van de Voort marcov at stack.nl
Mon Sep 16 11:14:23 CEST 2013


In our previous episode, Michael Schnell said:
> > As we have already written in some previous mails to there is a global 
> > event procedure to wake up the main thread that is triggered when 
> > something is queued. The LCL uses this already and other programs 
> > could use a TEvent or whatever.
> 
> Could you elaborate on this ? Is this "triggering" done by some kind of 
> self-piping or using an OS semaphore ? Is it provided for all OSes and Archs

Afaik it is implemented in the checksynchronize call in a platform dependent
manner. It assumes that you run checksynchronize in the idle event of your
eventloop though. (which should be the case for LCL implementations)

> Or do you mean a function call is provided that allows the user (or the 
> LCL) to implement such a functionality.

If you mean integrate with your own eventloop, then yes, make sure that your
idle event in your eventloop calls checksyncrhonize.



More information about the fpc-pascal mailing list