If a thread tries to do a read on a channel, the thread wait until another thread does a write on it; at that moment, the transfer happens. If, during the time the thread is waiting for the transfer to take place, a third thread tries to do a read on the same channel, the effects are unpredictable.
|