webtier@glassfish.java.net

Re: [webtier] NPE-fix for configureValves in WebModule

From: Wolfram Rittmeyer <w.rittmeyer_at_jsptutorial.org>
Date: Wed, 25 Feb 2009 16:08:14 +0100

Oh my, I forgot to attach the diff. So now as simple text:

Index: web-glue/src/main/java/com/sun/enterprise/web/WebModule.java
===================================================================
--- web-glue/src/main/java/com/sun/enterprise/web/WebModule.java
(revision 24958)
+++ web-glue/src/main/java/com/sun/enterprise/web/WebModule.java
(working copy)
@@ -869,7 +869,7 @@
       * Configure the <code>WebModule</code> valves.
       */
      protected void configureValves(){
- if (iasBean.getValve() != null && iasBean.sizeValve() > 0) {
+ if (iasBean != null && iasBean.getValve() != null &&
iasBean.sizeValve() > 0) {
              com.sun.enterprise.deployment.runtime.web.Valve[] valves =
iasBean.getValve();
              for (com.sun.enterprise.deployment.runtime.web.Valve
valve: valves) {
                  addValve(valve);

--
Wolfram
w.rittmeyer_at_jsptutorial.org wrote:
> I have attached the diff that fixes the NullPointerException, Sahoo detected. I will commit it as soon as it is reviewed.
> 
> Thanks,
> 
> --
> Wolfram Rittmeyer
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: webtier-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: webtier-help_at_glassfish.dev.java.net
> 
>