On Thu, 30 Sep 2021 09:05:41 GMT, Daniel Fuchs <dfu...@openjdk.org> wrote:

>> I think it would be simpler to replace lines 101-103 just with 
>> `trans.close()`
>
> Strictly speaking to preserve the current behavior - that would be 
> `trans.getResponseBody().close();` isn't it?

HttpExchange.close() calls the close method on both streams and closing the 
output stream implicitly closes the input stream. So, they are equivalent.

-------------

PR: https://git.openjdk.java.net/jdk/pull/5352

Reply via email to