[jboss-remoting-commits] JBoss Remoting SVN: r3652 - remoting2/branches/2.x/src/main/org/jboss/remoting/transport/socket.
jboss-remoting-commits at lists.jboss.org
jboss-remoting-commits at lists.jboss.org
Sun Mar 16 01:32:07 EDT 2008
Author: ron.sigal at jboss.com
Date: 2008-03-16 01:32:06 -0400 (Sun, 16 Mar 2008)
New Revision: 3652
Modified:
remoting2/branches/2.x/src/main/org/jboss/remoting/transport/socket/MicroSocketClientInvoker.java
Log:
JBREM-932: In transport() checks remaining time > 0 before resetting socket's SO_TIMEOUT value.
Modified: remoting2/branches/2.x/src/main/org/jboss/remoting/transport/socket/MicroSocketClientInvoker.java
===================================================================
--- remoting2/branches/2.x/src/main/org/jboss/remoting/transport/socket/MicroSocketClientInvoker.java 2008-03-15 09:10:59 UTC (rev 3651)
+++ remoting2/branches/2.x/src/main/org/jboss/remoting/transport/socket/MicroSocketClientInvoker.java 2008-03-16 05:32:06 UTC (rev 3652)
@@ -743,8 +743,11 @@
if (tempTimeout >= 0)
{
- savedTimeout = socketWrapper.getTimeout();
- socketWrapper.setTimeout((int) (tempTimeout - (System.currentTimeMillis() - start)));
+ timeLeft = (int) (tempTimeout - (System.currentTimeMillis() - start));
+ if (timeLeft <= 0)
+ break;
+ savedTimeout = socketWrapper.getTimeout();
+ socketWrapper.setTimeout(timeLeft);
}
long end = System.currentTimeMillis() - start;
More information about the jboss-remoting-commits
mailing list