**Issue**
A failure in this test was observed whereby an unexpected connection from a 
client that was not created by the test caused the test to unsucessfully 
complete. 

**Solution**
When a connection is accepted by the ServerSocket, some verification of the 
Request URI and of the Request Path is conducted. If the client connection is 
found to be invalid or external to the test, the connection is closed. The 
ServerSocket will continue to accept new connections until the correct 
parameters are met. Once a valid connection is accepted, the test behaves 
exactly as it previously did.

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

Commit messages:
 - 8286962: java/net/httpclient/ServerCloseTest.java failed once with 
ConnectException

Changes: https://git.openjdk.org/jdk/pull/9155/files
 Webrev: https://webrevs.openjdk.java.net/?repo=jdk&pr=9155&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8286962
  Stats: 89 lines in 1 file changed: 37 ins; 31 del; 21 mod
  Patch: https://git.openjdk.org/jdk/pull/9155.diff
  Fetch: git fetch https://git.openjdk.org/jdk pull/9155/head:pull/9155

PR: https://git.openjdk.org/jdk/pull/9155

Reply via email to