src/solaris/classes/sun/nio/ch/Port.java
Print this page
rev 8822 : 8024854: PPC64: Basic changes and files to build the class library on AIX
Reviewed-by: alanb, prr, sla, chegar, michaelm, mullan, art
Contributed-by: luchsh@linux.vnet.ibm.com, spoole@linux.vnet.ibm.com, thomas.stuefe@sap.com
@@ -75,15 +75,25 @@
fdToChannelLock.writeLock().unlock();
}
}
/**
+ * Callback method for implementations that need special handling when fd is
+ * removed (currently only needed in the AIX-Port - see AixPollPort.java).
+ */
+ protected void preUnregister(int fd) {
+ // Do nothing by default.
+ }
+
+ /**
* Unregister channel identified by its file descriptor
*/
final void unregister(int fd) {
boolean checkForShutdown = false;
+ preUnregister(fd);
+
fdToChannelLock.writeLock().lock();
try {
fdToChannel.remove(Integer.valueOf(fd));
// last key to be removed so check if group is shutdown