ASF Bugzilla – Attachment 32138 Details for
Bug 53411
NullPointerException in org.apache.tomcat.util.buf.CharChunk
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch for the enhancements mentioned above
Patch (text/plain), 1.87 KB, created by
Hariharan, R
on 2014-10-22 14:58:52 UTC
(
hide
)
Description:
Patch for the enhancements mentioned above
Filename:
MIME Type:
Creator:
Hariharan, R
Created:
2014-10-22 14:58:52 UTC
Size:
1.87 KB
patch
obsolete
>Index: Mapper.java >=================================================================== >--- Mapper.java (revision 1633619) >+++ Mapper.java (working copy) >@@ -677,6 +677,10 @@ > MappingData mappingData) > throws Exception { > >+ if (defaultHostName == null) { >+ return; >+ } >+ > if (host.isNull()) { > host.getCharChunk().append(defaultHostName); > } >Index: MapperListener.java >=================================================================== >--- MapperListener.java (revision 1633619) >+++ MapperListener.java (working copy) >@@ -257,35 +257,11 @@ > > Engine engine = (Engine) service.getContainer(); > String defaultHost = engine.getDefaultHost(); >- >- boolean found = false; >- >- if (defaultHost != null && defaultHost.length() >0) { >- Container[] containers = engine.findChildren(); >- >- for (Container container : containers) { >- Host host = (Host) container; >- if (defaultHost.equalsIgnoreCase(host.getName())) { >- found = true; >- break; >- } >- >- String[] aliases = host.findAliases(); >- for (String alias : aliases) { >- if (defaultHost.equalsIgnoreCase(alias)) { >- found = true; >- break; >- } >- } >- } >- } >- >- if(found) { >- mapper.setDefaultHostName(defaultHost); >- } else { >- log.warn(sm.getString("mapperListener.unknownDefaultHost", >- defaultHost, service)); >- } >+ >+ //Calling set default host directly because if we have >+ //null as default host then Tomcat should stop instead >+ //of just giving a warning >+ mapper.setDefaultHostName(defaultHost); > } > >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 53411
: 32138