This is an automated email from the ASF dual-hosted git repository.
markt-asf pushed a commit to branch 10.1.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git
The following commit(s) were added to refs/heads/10.1.x by this push:
new 27dd1de46d Fix failing tests
27dd1de46d is described below
commit 27dd1de46dc5dfb7cb958b21315f060322d01c80
Author: Mark Thomas <[email protected]>
AuthorDate: Fri Nov 6 13:48:14 2026 +0000
Fix failing tests
---
java/org/apache/catalina/mapper/Mapper.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/java/org/apache/catalina/mapper/Mapper.java
b/java/org/apache/catalina/mapper/Mapper.java
index a087c0ad8d..118e6d12ce 100644
--- a/java/org/apache/catalina/mapper/Mapper.java
+++ b/java/org/apache/catalina/mapper/Mapper.java
@@ -738,7 +738,7 @@ public final class Mapper {
boolean trailingPeriodRemoved = false;
MappedHost mappedHost = null;
try {
- if (host.charAt(host.length() - 1) == '.') {
+ if (host.length() > 0 && host.charAt(host.length() - 1) == '.') {
host.setEnd(host.getEnd() - 1);
trailingPeriodRemoved = true;
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]