Author: sebb
Date: Thu Dec 13 07:47:40 2007
New Revision: 603941
URL: http://svn.apache.org/viewvc?rev=603941&view=rev
Log:
Avoid possible NPE; revert to original close method
Modified:
jakarta/jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSampler2.java
Modified:
jakarta/jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSampler2.java
URL:
http://svn.apache.org/viewvc/jakarta/jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSampler2.java?rev=603941&r1=603940&r2=603941&view=diff
==============================================================================
---
jakarta/jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSampler2.java
(original)
+++
jakarta/jmeter/trunk/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPSampler2.java
Thu Dec 13 07:47:40 2007
@@ -1072,7 +1072,10 @@
{
Map.Entry entry = (Map.Entry) it.next();
HttpClient cl = (HttpClient) entry.getValue();
-
((SimpleHttpConnectionManager)cl.getHttpConnectionManager()).shutdown();//
Closes the connection
+ // Can cause NPE in HttpClient 3.1
+
//((SimpleHttpConnectionManager)cl.getHttpConnectionManager()).shutdown();//
Closes the connection
+ // Revert to original method:
+ cl.getHttpConnectionManager().closeIdleConnections(-1000);//
Closes the connection
}
map.clear();
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]