Author: ron.sigal(a)jboss.com
Date: 2008-04-30 01:31:09 -0400 (Wed, 30 Apr 2008)
New Revision: 4098
Modified:
remoting2/branches/2.x/src/main/org/jboss/remoting/transport/socket/SocketServerInvoker.java
Log:
JBREM-930: AcceptThread returns if ServerSocket is closed.
Modified:
remoting2/branches/2.x/src/main/org/jboss/remoting/transport/socket/SocketServerInvoker.java
===================================================================
---
remoting2/branches/2.x/src/main/org/jboss/remoting/transport/socket/SocketServerInvoker.java 2008-04-30
05:30:14 UTC (rev 4097)
+++
remoting2/branches/2.x/src/main/org/jboss/remoting/transport/socket/SocketServerInvoker.java 2008-04-30
05:31:09 UTC (rev 4098)
@@ -170,9 +170,9 @@
ServerSocket oldServerSocket = acceptThreads[i].getServerSocket();
InetAddress address = oldServerSocket.getInetAddress();
int port = oldServerSocket.getLocalPort();
- oldServerSocket.close();
ServerSocket newServerSocket = createServerSocket(port, backlog, address);
acceptThreads[i].setServerSocket(newServerSocket);
+ oldServerSocket.close();
log.info(acceptThreads[i] + " has been updated with new
ServerSocket");
}
}
@@ -1006,6 +1006,7 @@
if(running)
{
log.error(this + " failed to handle socket", ex);
+ if (serverSocket.isClosed()) return;
}
else
{
Show replies by date