--- a/jdk/src/share/classes/sun/nio/ch/Net.java Mon Jan 20 09:20:13 2014 +0100
+++ b/jdk/src/share/classes/sun/nio/ch/Net.java Mon Jan 20 09:24:25 2014 +0100
@@ -581,9 +581,34 @@
private static native void initIDs();
+ /**
+ * Event masks for the various poll system calls.
+ * They will be set platform dependant in the static initializer below.
+ */
+ public static final short POLLIN;
+ public static final short POLLOUT;
+ public static final short POLLERR;
+ public static final short POLLHUP;
+ public static final short POLLNVAL;
+ public static final short POLLCONN;
+
+ static native short pollinValue();
+ static native short polloutValue();
+ static native short pollerrValue();
+ static native short pollhupValue();
+ static native short pollnvalValue();
+ static native short pollconnValue();
+
static {
IOUtil.load();
initIDs();
+
+ POLLIN = pollinValue();
+ POLLOUT = polloutValue();
+ POLLERR = pollerrValue();
+ POLLHUP = pollhupValue();
+ POLLNVAL = pollnvalValue();
+ POLLCONN = pollconnValue();
}
}