United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-6526158 HttpExchange.getRequestBody().close() throws Exception
JDK-6526158 : HttpExchange.getRequestBody().close() throws Exception

Details
Type:
Bug
Submit Date:
2007-02-16
Status:
Resolved
Updated Date:
2010-04-03
Project Name:
JDK
Resolved Date:
2007-08-22
Component:
core-libs
OS:
generic
Sub-Component:
java.net
CPU:
generic
Priority:
P3
Resolution:
Fixed
Affected Versions:
6
Fixed Versions:
6u10 (b02)

Related Reports
Backport:

Sub Tasks

Description
HttpExchange.getRequestBody().close() throws the following excpetion when the data is not read from the InputStream. In Many cases, he application may not need anything from InputStream.

java.io.IOException: Stream is closed
        at sun.net.httpserver.FixedLengthInputStream.readImpl(FixedLengthInputStream.java:31)
        at sun.net.httpserver.LeftOverInputStream.drain(LeftOverInputStream.java:91)
        at sun.net.httpserver.LeftOverInputStream.close(LeftOverInputStream.java:48)

Attaching the program to produce it. Alos need the port of http.jar for JDK 1.5

                                    

Comments
EVALUATION

fixing in 6u3. It is too late for 6u2.
                                     
2007-03-14



Hardware and Software, Engineered to Work Together