This is an automated email from the ASF dual-hosted git repository.
markt pushed a commit to branch 10.0.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git
The following commit(s) were added to refs/heads/10.0.x by this push:
new f71464a3e3 Refactor to avoid use of Hashtable. No functional change.
f71464a3e3 is described below
commit f71464a3e35b596be28d2dbf9914d833b223e41d
Author: Mark Thomas <[email protected]>
AuthorDate: Thu Sep 15 15:48:18 2022 +0100
Refactor to avoid use of Hashtable. No functional change.
---
java/org/apache/catalina/valves/rewrite/RewriteValve.java | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/java/org/apache/catalina/valves/rewrite/RewriteValve.java
b/java/org/apache/catalina/valves/rewrite/RewriteValve.java
index 07f718df26..b26e1bdbd7 100644
--- a/java/org/apache/catalina/valves/rewrite/RewriteValve.java
+++ b/java/org/apache/catalina/valves/rewrite/RewriteValve.java
@@ -24,10 +24,10 @@ import java.io.StringReader;
import java.nio.charset.Charset;
import java.nio.charset.StandardCharsets;
import java.util.ArrayList;
-import java.util.Hashtable;
import java.util.List;
import java.util.Map;
import java.util.StringTokenizer;
+import java.util.concurrent.ConcurrentHashMap;
import jakarta.servlet.ServletException;
import jakarta.servlet.http.Cookie;
@@ -102,7 +102,7 @@ public class RewriteValve extends ValveBase {
/**
* Maps to be used by the rules.
*/
- protected Map<String, RewriteMap> maps = new Hashtable<>();
+ protected Map<String, RewriteMap> maps = new ConcurrentHashMap<>();
/**
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]