Author: ab
Date: Fri Sep 17 14:46:16 2010
New Revision: 998156
URL: http://svn.apache.org/viewvc?rev=998156&view=rev
Log:
NUTCH-862 HttpClient null pointer exception.
Modified:
nutch/branches/branch-1.2/CHANGES.txt
nutch/branches/branch-1.2/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpResponse.java
Modified: nutch/branches/branch-1.2/CHANGES.txt
URL:
http://svn.apache.org/viewvc/nutch/branches/branch-1.2/CHANGES.txt?rev=998156&r1=998155&r2=998156&view=diff
==============================================================================
--- nutch/branches/branch-1.2/CHANGES.txt (original)
+++ nutch/branches/branch-1.2/CHANGES.txt Fri Sep 17 14:46:16 2010
@@ -2,6 +2,8 @@ Nutch Change Log
Release 1.2 - 08/07/2010
+* NUTCH-862 HttpClient null pointer exception (Sebastian Nagel via ab)
+
* NUTCH-905 Configurable file protocol parent directory crawling (Thorsten
Scherler, mattmann, ab)
* NUTCH-877 Allow setting of slop values for non-quote phrase queries on
query-basic plugin (kubes via jnioche)
Modified:
nutch/branches/branch-1.2/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpResponse.java
URL:
http://svn.apache.org/viewvc/nutch/branches/branch-1.2/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpResponse.java?rev=998156&r1=998155&r2=998156&view=diff
==============================================================================
---
nutch/branches/branch-1.2/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpResponse.java
(original)
+++
nutch/branches/branch-1.2/src/plugin/protocol-httpclient/src/java/org/apache/nutch/protocol/httpclient/HttpResponse.java
Fri Sep 17 14:46:16 2010
@@ -134,7 +134,9 @@ public class HttpResponse implements Res
if (code == 200) throw new IOException(e.toString());
// for codes other than 200 OK, we are fine with empty content
} finally {
- in.close();
+ if (in != null) {
+ in.close();
+ }
get.abort();
}