diff options
author | Mathias Kinzler <mathias.kinzler@sap.com> | 2010-08-10 15:58:21 +0200 |
---|---|---|
committer | Mathias Kinzler <mathias.kinzler@sap.com> | 2010-08-10 15:58:21 +0200 |
commit | fe76b410386dc6ec45195878e9a59f74f2768685 (patch) | |
tree | 5401a29c5ced611cfe4c35c29d968480874cdd7f /org.eclipse.jgit | |
parent | 9a6a433576c8b1cedb5f3aff9cfecb8217881ddf (diff) | |
download | jgit-fe76b410386dc6ec45195878e9a59f74f2768685.tar.gz jgit-fe76b410386dc6ec45195878e9a59f74f2768685.zip |
TransportHttp does not honor timeout setting
This can result in an infinitely hanging IDE.
Change-Id: I669bc8d220a07011a42edf79de31825305ff3763
Signed-off-by: Mathias Kinzler <mathias.kinzler@sap.com>
Diffstat (limited to 'org.eclipse.jgit')
-rw-r--r-- | org.eclipse.jgit/src/org/eclipse/jgit/transport/TransportHttp.java | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/TransportHttp.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/TransportHttp.java index 0f4c1314a3..333f91bf09 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/TransportHttp.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/TransportHttp.java @@ -379,6 +379,8 @@ public class TransportHttp extends HttpTransport implements WalkTransport, conn.setRequestProperty(HDR_ACCEPT_ENCODING, ENCODING_GZIP); conn.setRequestProperty(HDR_PRAGMA, "no-cache");//$NON-NLS-1$ conn.setRequestProperty(HDR_USER_AGENT, userAgent); + conn.setConnectTimeout(getTimeout() * 1000); + conn.setReadTimeout(getTimeout() * 1000); return conn; } |