Author: sjmenden
Date: 2012-03-01 18:31:39 -0500 (Thu, 01 Mar 2012)
New Revision: 1990
Modified:
branches/JBOSSWEB_2_1_10_GA_JBPAPP-8326/java/org/jboss/web/rewrite/TomcatResolver.java
Log:
Applied patch from
https://issues.jboss.org/browse/JBWEB-157
Modified:
branches/JBOSSWEB_2_1_10_GA_JBPAPP-8326/java/org/jboss/web/rewrite/TomcatResolver.java
===================================================================
---
branches/JBOSSWEB_2_1_10_GA_JBPAPP-8326/java/org/jboss/web/rewrite/TomcatResolver.java 2012-03-01
23:22:13 UTC (rev 1989)
+++
branches/JBOSSWEB_2_1_10_GA_JBPAPP-8326/java/org/jboss/web/rewrite/TomcatResolver.java 2012-03-01
23:31:39 UTC (rev 1990)
@@ -56,7 +56,7 @@
return request.getHeader("forwarded");
} else if (key.equals("HTTP_HOST")) {
String host = request.getHeader("host");
- int index = host.indexOf(':');
+ int index = host !=null ? host.indexOf(':') : -1;
if (index != -1)
host = host.substring(0, index);
return host;