This is an automated email from the ASF dual-hosted git repository. markt pushed a commit to branch 8.5.x in repository https://gitbox.apache.org/repos/asf/tomcat.git
commit a26978b45d165e429c44c58022a4a8db93841da6 Author: Mark Thomas <ma...@apache.org> AuthorDate: Wed Sep 15 13:52:42 2021 +0100 Move debug statement inside sync block Ensures that the values logged are consistent with the values processed. --- java/org/apache/coyote/http2/WindowAllocationManager.java | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/java/org/apache/coyote/http2/WindowAllocationManager.java b/java/org/apache/coyote/http2/WindowAllocationManager.java index 96016cc..6c824a5 100644 --- a/java/org/apache/coyote/http2/WindowAllocationManager.java +++ b/java/org/apache/coyote/http2/WindowAllocationManager.java @@ -172,12 +172,13 @@ class WindowAllocationManager { private void notify(int notifyTarget) { - if (log.isDebugEnabled()) { - log.debug(sm.getString("windowAllocationManager.notify", stream.getConnectionId(), - stream.getIdAsString(), Integer.toString(waitingFor), Integer.toString(notifyTarget))); - } synchronized (stream) { + if (log.isDebugEnabled()) { + log.debug(sm.getString("windowAllocationManager.notify", stream.getConnectionId(), + stream.getIdAsString(), Integer.toString(waitingFor), Integer.toString(notifyTarget))); + } + if ((notifyTarget & waitingFor) > NONE) { // Reset this here so multiple notifies (possible with a // backlog containing multiple streams and small window updates) --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org