Skip to content

Commit 759db92

Browse files
Merge pull request #915 from nandika/master
Not throw an exception when the client closes the connection
2 parents 2cc2223 + 2d41d59 commit 759db92

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

modules/transport/http/src/main/java/org/apache/axis2/transport/http/server/AxisHttpConnectionImpl.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,8 @@ public ClassicHttpRequest receiveRequest() throws HttpException, IOException {
229229
this.inbuffer.clear();
230230
final int i = this.inbuffer.readLine(headLine, this.in);
231231
if (i == -1) {
232-
throw new IOException("readLine() from SessionInputBufferImpl returned -1 in method receiveRequest()");
232+
//throw new IOException("readLine() from SessionInputBufferImpl returned -1 in method receiveRequest()");
233+
return null;
233234
}
234235

235236
final Header[] headers = AbstractMessageParser.parseHeaders(

modules/transport/http/src/main/java/org/apache/axis2/transport/http/server/AxisHttpService.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ public void handleRequest(final AxisHttpConnection conn, final HttpContext local
151151
try {
152152
request = conn.receiveRequest();
153153
if (request == null) {
154-
LOG.error("AxisHttpService.handleRequest() returning on null request, will close the connection");
154+
LOG.info("AxisHttpService.handleRequest() returning on null request, will close the connection");
155155
conn.close();
156156
return;
157157
}

0 commit comments

Comments
 (0)