1 Reply Latest reply on Aug 10, 2004 9:24 AM by Scott Stark

    Redundant code in AbstractWebContainer?

    Raja Master

      I was doing some debug in the AbstractWebContainer when i came across this piece of code in the parseWebAppDescriptors method.

      // Create a java:comp/env environment unique for the web application
       log.debug("Creating ENC using ClassLoader: "+loader);
       ClassLoader parent = loader.getParent();
       while( parent != null )
       parent = parent.getParent();
       envCtx = (Context) iniCtx.lookup("java:comp");

      There is no reference to the "parent" object after the while loop. Why is this code in there? Am i missing something obvious?

      Im trying to debug a scenario where a scoped class loader gives a "NameNotFoundException: comp not bound" error. I found in the bug reports that its been fixed with 3.2 and im using 3.2.2RC4 and still getting the above mentioned error.