[fpc-pascal] Stack problem in externally called callback function
wimpienortje at gmail.com
Sun Aug 2 20:17:24 CEST 2009
Thanks, I'll have a look
Jonas Maebe wrote:
> On 02 Aug 2009, at 20:02, Wimpie Nortje wrote:
>> Thanks for the response.
>> The library uses a centralised function to start all its threads
>> using pthread_create. If I can make this central function inform FPC
>> about all the threads created, would this work?
> There is no interface in the RTL to inform it about newly created
> external threads, so it would be quite hard.
>> Assuming it would work: what information would FPC require? When
>> would this info be required, before or after thread creation? What
>> needs to be done on the FPC side with this info?
> Look at rtl/unix/cthreads.pp, in the functions CBeginThread/ThreadMain
> and CEndThread (they also call generic code from rtl/inc/thread.inc,
> such as InitThread and DoneThread).
> fpc-pascal maillist - fpc-pascal at lists.freepascal.org
More information about the fpc-pascal