From: jfclere Date: Tue, 29 Sep 2009 12:20:57 +0000 (+0000) Subject: timeout can't be negative... X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=a5724cb4cedf74cb7486d81cfeb6169f0c46f649;p=tomcat7.0 timeout can't be negative... git-svn-id: https://svn.apache.org/repos/asf/tomcat/trunk@819899 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/java/org/apache/tomcat/util/net/SocketProperties.java b/java/org/apache/tomcat/util/net/SocketProperties.java index e17f5cd0f..37f115855 100644 --- a/java/org/apache/tomcat/util/net/SocketProperties.java +++ b/java/org/apache/tomcat/util/net/SocketProperties.java @@ -203,7 +203,7 @@ public class SocketProperties { if (soLingerOn != null && soLingerTime != null) socket.setSoLinger(soLingerOn.booleanValue(), soLingerTime.intValue()); - if (soTimeout != null) + if (soTimeout != null && soTimeout.intValue() >= 0) socket.setSoTimeout(soTimeout.intValue()); if (tcpNoDelay != null) socket.setTcpNoDelay(tcpNoDelay.booleanValue()); @@ -222,7 +222,7 @@ public class SocketProperties { performanceBandwidth.intValue()); if (soReuseAddress != null) socket.setReuseAddress(soReuseAddress.booleanValue()); - if (soTimeout != null) + if (soTimeout != null && soTimeout.intValue() >= 0) socket.setSoTimeout(soTimeout.intValue()); } @@ -422,4 +422,4 @@ public class SocketProperties { -} \ No newline at end of file +}