[fpc-pascal] Call function in shared library from multiple threads

fredvs fiens at hotmail.com
Fri Mar 31 17:42:24 CEST 2017


Hello.


Michael Van Canneyt wrote
> To fix that, you can do the following. 
> In the library startup code, create a dummy thread. 
> This will initialize the threads mechanism:
> 
>    with TThread.Create(False) do
> 
> end.

I use this for initialize my libraries:

 With TThread.Create(False) do Terminate;

It works ok but there is that warning after compiling:


> Z:\home\fred\uos\examples\uos.pas(7438,29) Warning: (4046) Constructing a
> class "TThread" with abstract method "Execute"

Huh, is it Is it serious doctor?

Fre;D





-----
Many thanks ;-)
--
View this message in context: http://free-pascal-general.1045716.n5.nabble.com/Call-function-in-shared-library-from-multiple-threads-tp5728035p5728057.html
Sent from the Free Pascal - General mailing list archive at Nabble.com.



More information about the fpc-pascal mailing list