You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2026/10/08 11:19:42 UTC
(tomcat) branch 11.0.x updated: Follow-up to "Reset the default host when it is removed from the mapper"
This is an automated email from the ASF dual-hosted git repository.
markt-asf pushed a commit to branch 11.0.x
in repository https://gitbox.apache.org/repos/asf/tomcat.git
The following commit(s) were added to refs/heads/11.0.x by this push:
new 9f85ec87b4 Follow-up to "Reset the default host when it is removed from the mapper"
9f85ec87b4 is described below
commit 9f85ec87b42598ffbcb259f0dc665160a699755a
Author: Mark Thomas <ma...@apache.org>
AuthorDate: Thu Oct 8 12:19:20 2026 +0100
Follow-up to "Reset the default host when it is removed from the mapper"
Clear the default first so a missed host lookup doesn't fallback to the
stale default.
---
java/org/apache/catalina/mapper/Mapper.java | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/java/org/apache/catalina/mapper/Mapper.java b/java/org/apache/catalina/mapper/Mapper.java
index 76dbe45391..65589455f4 100644
--- a/java/org/apache/catalina/mapper/Mapper.java
+++ b/java/org/apache/catalina/mapper/Mapper.java
@@ -245,13 +245,12 @@ public final class Mapper {
}
MappedHost[] newHosts = new MappedHost[hosts.length - 1];
if (removeMap(hosts, newHosts, alias)) {
- hosts = newHosts;
hostMapping.getRealHost().removeAlias(hostMapping);
if (defaultHost == hostMapping) {
defaultHost = null;
}
+ hosts = newHosts;
}
-
}
/**
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org