summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrian Carlstrom <bdc@google.com>2010-12-04 23:42:26 -0800
committerAndroid Git Automerger <android-git-automerger@android.com>2010-12-04 23:42:26 -0800
commitc9a8b4e3604e8512bd028025f1a849a8b21fe951 (patch)
treeb2d1adbee8be1ea7f9dc8637fb559743150b2085
parent723b2f0ba0f78bc610498372ee7441ff5fc4eea6 (diff)
parentf0035c0e7077bc2d7a8aaf6516d96b0d2b1ba22d (diff)
downloadexternal_apache-http-c9a8b4e3604e8512bd028025f1a849a8b21fe951.zip
external_apache-http-c9a8b4e3604e8512bd028025f1a849a8b21fe951.tar.gz
external_apache-http-c9a8b4e3604e8512bd028025f1a849a8b21fe951.tar.bz2
am f0035c0e: Set per request socket timeout on reused connections
* commit 'f0035c0e7077bc2d7a8aaf6516d96b0d2b1ba22d': Set per request socket timeout on reused connections
-rw-r--r--src/org/apache/http/impl/client/DefaultRequestDirector.java8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/org/apache/http/impl/client/DefaultRequestDirector.java b/src/org/apache/http/impl/client/DefaultRequestDirector.java
index 511f8a0..6df6246 100644
--- a/src/org/apache/http/impl/client/DefaultRequestDirector.java
+++ b/src/org/apache/http/impl/client/DefaultRequestDirector.java
@@ -346,7 +346,13 @@ public class DefaultRequestDirector implements RequestDirector {
// Reopen connection if needed
if (!managedConn.isOpen()) {
managedConn.open(route, context, params);
- }
+ }
+ // BEGIN android-added
+ else {
+ // b/3241899 set the per request timeout parameter on reused connections
+ managedConn.setSocketTimeout(HttpConnectionParams.getSoTimeout(params));
+ }
+ // END android-added
try {
establishRoute(route, context);