tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Pedro Morais <p...@rnl.ist.utl.pt>
Subject Re: ErrorReportValve
Date Thu, 06 Dec 2001 11:05:54 GMT
Em Quinta, 6 de Dezembro de 2001 10:54, Pedro Morais escreveu:
> Hi!
>
> I've being looking at the code for TC 4.0.1 and I think it's impossible to
> disable the ErrorReportValve.

Ok, replying to my own email.
I've found out that I can set the errorReportValve value on an Host element;
there problem is, I havent been able to find a valid way to set it to null.
Do you think this patch is valid?
It ignore the class name if it's the empty string.
Thansk.

--- catalina/src/share/org/apache/catalina/core/StandardHost.java       
2001/10/25 00:23:02     1.22
+++ catalina/src/share/org/apache/catalina/core/StandardHost.java       
2001/12/06 10:41:24
@@ -627,7 +627,8 @@
     public synchronized void start() throws LifecycleException {
 
         // Set error report valve
-        if (errorReportValveClass != null) {
+        if (errorReportValveClass != null &&
+           !"".equals(errorReportValveClass)) {
             try {
                 Valve valve = (Valve) Class.forName(errorReportValveClass)
                     .newInstance();


--
To unsubscribe, e-mail:   <mailto:tomcat-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:tomcat-dev-help@jakarta.apache.org>


Mime
View raw message