Author: markt
Date: Sun Jun 16 23:12:04 2013
New Revision: 1493607
URL: http://svn.apache.org/r1493607
Log:
Fix a FindBugs warning. Correctly handle a timeout.
Modified:
tomcat/trunk/java/org/apache/tomcat/websocket/AsyncChannelWrapperSecure.java
Modified:
tomcat/trunk/java/org/apache/tomcat/websocket/AsyncChannelWrapperSecure.java
URL:
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/tomcat/websocket/AsyncChannelWrapperSecure.java?rev=1493607&r1=1493606&r2=1493607&view=diff
==============================================================================
---
tomcat/trunk/java/org/apache/tomcat/websocket/AsyncChannelWrapperSecure.java
(original)
+++
tomcat/trunk/java/org/apache/tomcat/websocket/AsyncChannelWrapperSecure.java
Sun Jun 16 23:12:04 2013
@@ -472,7 +472,10 @@ public class AsyncChannelWrapperSecure i
public T get(long timeout, TimeUnit unit)
throws InterruptedException, ExecutionException,
TimeoutException {
- completionLatch.await(timeout, unit);
+ boolean latchResult = completionLatch.await(timeout, unit);
+ if (latchResult == false) {
+ throw new TimeoutException();
+ }
if (throwable != null) {
throw new ExecutionException(throwable);
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]