[Spread-users] Question about thread-safety

White Stuart - stwhit Stuart.White at acxiom.com
Fri Jun 13 10:07:34 EDT 2003

Hello all,

I'm a spread newbie - just downloaded a few days ago.  My question is
regarding using Spread in a threaded C application.

I would like to write an application that can simultaneously send and
receive messages.  In my main thread, I spawn another thread (the "message
handler" thread) and he loops forever calling SP_receive().  The main thread
loops, sending his messages via SP_multicast().

My question is this:  I'm getting spurrious failures, (getting errors like
ILLEGAL_SESSION from SP_receive) and I'm wondering what synchronization is
appropriate for using spread in a threaded application?  Do I need to make
sure only 1 thread is calling an SP_* function at-a-time?

Thanks much!


Stuart White

Acxiom Corporation
AbiliTec Architecture
Email: stuart.white at acxiom.com
Phone: 501.329.5975

The information contained in this communication is
confidential, is intended only for the use of the recipient
named above, and may be legally privileged.
If the reader of this message is not the intended
recipient, you are hereby notified that any dissemination, 
distribution, or copying of this communication is strictly
If you have received this communication in error,
please re-send this communication to the sender and
delete the original message or any copy of it from your
computer system. Thank You.

More information about the Spread-users mailing list