hc-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michael Pujos (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (HTTPCORE-263) IndexOutOfBoundsException thrown in AbstractSessionInputBuffer.readLine()
Date Tue, 05 Jul 2011 20:08:17 GMT

     [ https://issues.apache.org/jira/browse/HTTPCORE-263?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Michael Pujos updated HTTPCORE-263:
-----------------------------------

    Description: 
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 for AbstractSessionInputBuffer
doesn't match the exact line number of the offending append() call (probably due to Proguard),
but there are 2 such calls in this function, and it looks like one of them is called with
len = -1, triggering the IndexOutOfBoundsException in append()

  was:
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 for AbstractSessionInputBuffer
doesn't match the exact line number of the offending append() call,
but there are 2 such calls in this function, and it looks like one of them is called with
len = -1, triggering the IndexOutOfBoundsException in append()


> IndexOutOfBoundsException thrown in AbstractSessionInputBuffer.readLine()
> -------------------------------------------------------------------------
>
>                 Key: HTTPCORE-263
>                 URL: https://issues.apache.org/jira/browse/HTTPCORE-263
>             Project: HttpComponents HttpCore
>          Issue Type: Bug
>          Components: HttpCore
>    Affects Versions: 4.1.1
>         Environment: reported on Android  2.3.3 using repackaged httpcore 4.1.1, optimized
and obfuscated with Proguard
>            Reporter: Michael Pujos
>            Priority: Minor
>
> 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 for AbstractSessionInputBuffer
doesn't match the exact line number of the offending append() call (probably due to Proguard),
> but there are 2 such calls in this function, and it looks like one of them is called
with len = -1, triggering the IndexOutOfBoundsException in append()

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@hc.apache.org
For additional commands, e-mail: dev-help@hc.apache.org


Mime
View raw message