[Spread-users] spread 4.0rc2, C and multithreading
John Lane Schultz
jschultz at spreadconcepts.com
Mon Oct 30 11:53:26 EST 2006
jabe at gfz-potsdam.de wrote:
> I try to use spread in a multithreaded environment.
> The main thread does all the connection handling while the listener thread
> reads incoming messages.
> When I disconnect from the main thread, the listener thread receives an error
> (connection closed by spread) and terminates. That behavior is intended.
>
> When I connect and disconnect, everything works as expected.
> After connecting again, the listener thread will neither receive a message nor
> an error from spread anymore. The thread block in SP_receive and even if I
> call disconnect from the main thread, SP_receive does not receive the
> "connection closes by spread" error.
>
> Do I miss something important?
>
Jan,
Thanks for the tip. Your example looks like it should work. I'll investigate
and see if I can reproduce your behavior and debug it.
Thanks!
--
John Schultz
Spread Concepts LLC
Phn: 443 838 2200
Fax: 301 560 8875
More information about the Spread-users
mailing list