[prev in list] [next in list] [prev in thread] [next in thread]
List: httpcomponents-commits
Subject: svn commit: r499879 -
From: olegk () apache ! org
Date: 2007-01-25 18:19:00
Message-ID: 20070125181900.1C7231A981A () eris ! apache ! org
[Download RAW message or body]
Author: olegk
Date: Thu Jan 25 10:18:59 2007
New Revision: 499879
URL: http://svn.apache.org/viewvc?view=rev&rev=499879
Log:
Fixed problem with handling cancelled sessions while re-triggering input notification \
for buffering sessions
Modified:
jakarta/httpcomponents/httpcore/trunk/module-nio/src/main/java/org/apache/http/nio/impl/reactor/BaseIOReactor.java
Modified: jakarta/httpcomponents/httpcore/trunk/module-nio/src/main/java/org/apache/http/nio/impl/reactor/BaseIOReactor.java
URL: http://svn.apache.org/viewvc/jakarta/httpcomponents/httpcore/trunk/module-nio/src \
/main/java/org/apache/http/nio/impl/reactor/BaseIOReactor.java?view=diff&rev=499879&r1=499878&r2=499879
==============================================================================
--- jakarta/httpcomponents/httpcore/trunk/module-nio/src/main/java/org/apache/http/nio/impl/reactor/BaseIOReactor.java \
(original)
+++ jakarta/httpcomponents/httpcore/trunk/module-nio/src/main/java/org/apache/http/nio/impl/reactor/BaseIOReactor.java \
Thu Jan 25 10:18:59 2007 @@ -32,6 +32,7 @@
package org.apache.http.nio.impl.reactor;
import java.io.IOException;
+import java.nio.channels.CancelledKeyException;
import java.nio.channels.SelectionKey;
import java.util.Iterator;
import java.util.Set;
@@ -104,14 +105,18 @@
continue;
}
}
- int ops = session.getEventMask();
- if ((ops & EventMask.READ) > 0) {
- this.eventDispatch.inputReady(session);
- if (bufStatus != null) {
- if (!bufStatus.hasBufferedInput()) {
- it.remove();
+ try {
+ int ops = session.getEventMask();
+ if ((ops & EventMask.READ) > 0) {
+ this.eventDispatch.inputReady(session);
+ if (bufStatus != null) {
+ if (!bufStatus.hasBufferedInput()) {
+ it.remove();
+ }
}
}
+ } catch (CancelledKeyException ex) {
+ it.remove();
}
}
}
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic