jdk17u-dev icon indicating copy to clipboard operation
jdk17u-dev copied to clipboard

8358764: (sc) SocketChannel.close when thread blocked in read causes connection to be reset (win)

Open GoeLin opened this issue 4 weeks ago • 13 comments
trafficstars

I backport this for parity with 17.0.18-oracle.

Needed resolve and adaptions:

Net.java: resolved static initializer. SocketChannelImpl.java: In implCloseBlockingMode(), the code guarded by the new condition is not in 17. Omitted. Update: I added this later.

Net.c: Copyright.

The test exercises platform and virtual threads. I simplified this to what is supported in 17. See extra commit.


Progress

  • [x] Change must be properly reviewed (1 review required, with at least 1 Reviewer)
  • [x] Change must not contain extraneous whitespace
  • [x] Commit message must refer to an issue
  • [ ] JDK-8358764 needs maintainer approval

Issue

  • JDK-8358764: (sc) SocketChannel.close when thread blocked in read causes connection to be reset (win) (Bug - P3 - Requested)

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.org/jdk17u-dev.git pull/4076/head:pull/4076
$ git checkout pull/4076

Update a local copy of the PR:
$ git checkout pull/4076
$ git pull https://git.openjdk.org/jdk17u-dev.git pull/4076/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 4076

View PR using the GUI difftool:
$ git pr show -t 4076

Using diff file

Download this PR as a diff file:
https://git.openjdk.org/jdk17u-dev/pull/4076.diff

Using Webrev

Link to Webrev Comment

GoeLin avatar Oct 21 '25 10:10 GoeLin