Skip to content

Commit

Permalink
8316031: SSLFlowDelegate should not log from synchronized block
Browse files Browse the repository at this point in the history
Backport-of: dc5ca1d3798727fd29a6a40e9f7777cb7f85c004
  • Loading branch information
dfuch committed Sep 21, 2023
1 parent c0adad2 commit cea4062
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -971,10 +971,12 @@ private void handleError(Throwable t) {

boolean stopped;

private synchronized void normalStop() {
if (stopped)
return;
stopped = true;
private void normalStop() {
synchronized (this) {
if (stopped)
return;
stopped = true;
}
reader.stop();
writer.stop();
// make sure the alpnCF is completed.
Expand Down
2 changes: 1 addition & 1 deletion test/jdk/java/net/httpclient/HttpClientLocalAddrTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
* @test
* @summary Tests HttpClient usage when configured with a local address to bind
* to, when sending requests
* @bug 8209137
* @bug 8209137 8316031
* @library /test/lib /test/jdk/java/net/httpclient/lib
*
* @build jdk.test.lib.net.SimpleSSLContext jdk.test.lib.net.IPSupport
Expand Down

1 comment on commit cea4062

@openjdk-notifier
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.