We are running an old version of Tomcat, and a new web application has caused a stack trace like this
Caused by: java.lang.StackOverflowError
at org.apache.catalina.startup.ContextConfig.populateSCIsForCacheEntry(ContextConfig.java:2269)
at org.apache.catalina.startup.ContextConfig.populateSCIsForCacheEntry(ContextConfig.java:2269)
at org.apache.catalina.startup.ContextConfig.populateSCIsForCacheEntry(ContextConfig.java:2269)
This has been mentioned at https://bz.apache.org/bugzilla/show_bug.cgi?id=53871, and later versions (like Tomcat 8) don't seem to be affected.
How can I fix this?