Link to home
Start Free TrialLog in
Avatar of zollen
zollen

asked on

Question about socket/Thread programming...

Hi Guys,

  If a thread calls a blocking socket.read(...), is it possible for another thread to wake up the blocking thread, so socket.read(...) return immediately


(2nd question: Is there any non-blocking socket.read(...)?)
stephen
ASKER CERTIFIED SOLUTION
Avatar of Mick Barry
Mick Barry
Flag of Australia image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of nebeker
nebeker

As an alternative to a non-blocking read, you can call "available()" to see if any data is there, before you commit to calling read().