JDK-7131399 : Poll system call appears to be broken on Mac OS [macosx]
  • Type: Bug
  • Status: Closed
  • Resolution: Fixed
  • Component: core-libs
  • Sub-Component: java.net
  • Priority: P3
  • Affected Version: 7,7u4
  • OS: os_x
  • CPU: generic,unknown
  • Submit Date: 2012-01-19
  • Updated Date: 2013-08-27
  • Resolved Date: 2012-03-27
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availabitlity Release.

To download the current JDK release, click here.
JDK 7
7u4 b11Fixed
Description
NET_Timeout() and NET_Poll() are not working on mac osx.

Comments
EVALUATION Actually this only happens with UDP sockets (j.n.DatagramSocket). It also happens with the NIO equivalent. And most significantly, it only happens with empty packets. ie. if a client sends an empty UDP message, then poll() does not wake up. It works in all other cases. Replacing poll() with select() fixes the problem.
2012-01-23

EVALUATION poll() system call is not firing on sockets. Need to define USE_SELECT in networking code to avoid calling NET_Poll() and implement NET_Timeout() using select() instead of poll.
2012-01-19