jira-importer opened a new issue, #1390:
URL: https://github.com/apache/httpcomponents-core/issues/1390

   **[Michael 
Pujos](https://issues.apache.org/jira/secure/ViewProfile.jspa?name=bubbleguuum)**
 opened 
**[HTTPCORE-263](https://issues.apache.org/jira/browse/HTTPCORE-263?redirect=false)**
 and commented
   
   I've got the exception below reported in my Android app using (repackaged) 
httpcore 4.1.1:
   
   java.lang.IndexOutOfBoundsException: off: 1088 len: -1 b.length: 8192
   at org.apache.http.util.CharArrayBuffer.append(SourceFile:185)
   at 
org.apache.http.impl.io.AbstractSessionInputBuffer.readLine(SourceFile:251)
   at org.apache.http.impl.io.HttpRequestParser.parseHead(SourceFile:90)
   at org.apache.http.impl.io.AbstractMessageParser.parseHead(SourceFile:252)
   parse
   at 
org.apache.http.impl.AbstractHttpServerConnection.receiveRequestHeader(SourceFile:242)
   at org.apache.http.protocol.HttpService.handleRequest(SourceFile:238)
   at 
org.teleal.cling.transport.impl.apache.HttpServerConnectionUpnpStream.run(SourceFile:116)
   at 
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1088)
   at 
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:581)
   at java.lang.Thread.run(Thread.java:1019)
   
   It seems to be very rare. Stack trace line number (185) in 
AbstractSessionInputBuffer doesn't exaclty match the exact line number of the 
offending append() call (probably due to Proguard).
   However,  there are 2 append() calls in readLine(), and it looks like one of 
them is called with len = -1, triggering the IndexOutOfBoundsException in 
append()
   
   
   ---
   
   **Affects:** 4.1.1
   
   **Attachments:**
   - 
[HttpCoreBug.java](https://issues.apache.org/jira/secure/attachment/12528620/HttpCoreBug.java)
 (_5.26 kB_)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to