bruno       2003/03/18 08:48:00

  Modified:    src/java/org/apache/cocoon/environment
                        AbstractEnvironment.java
  Log:
  Fixed a NPE in resolve(String systemId)
  
  Revision  Changes    Path
  1.4       +4 -3      
cocoon-2.1/src/java/org/apache/cocoon/environment/AbstractEnvironment.java
  
  Index: AbstractEnvironment.java
  ===================================================================
  RCS file: 
/home/cvs/cocoon-2.1/src/java/org/apache/cocoon/environment/AbstractEnvironment.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- AbstractEnvironment.java  12 Mar 2003 07:42:25 -0000      1.3
  +++ AbstractEnvironment.java  18 Mar 2003 16:48:00 -0000      1.4
  @@ -352,7 +352,7 @@
           // get the wrapper class - we don't want to import the wrapper directly
           // to avoid a direct dependency from the core to the deprecation package
           if ( null == avalonToCocoonSourceWrapper ) {
  -            synchronized (avalonToCocoonSourceWrapper) {
  +            synchronized (this) {
                   try {
                       Class clazz = 
ClassUtils.loadClass("org.apache.cocoon.components.source.impl.AvalonToCocoonSource");
                       avalonToCocoonSourceWrapper = clazz.getConstructor(new Class[] 
{ClassUtils.loadClass("org.apache.excalibur.source.Source"),
  @@ -360,7 +360,8 @@
                                                                                       
ClassUtils.loadClass("org.apache.cocoon.environment.Environment")});
                   } catch (Exception e) {
                       throw new ProcessingException("The deprecated resolve() method 
of the environment was called." 
  -                                                  +"Please either update your code 
to use the new resolveURI() method or" 
                                                  +" install the deprecation 
support.", e);
  +                                                  +"Please either update your code 
to use the new resolveURI() method or" 
  +                                                  +" install the deprecation 
support.", e);
                   }
               }
           }
  
  
  

Reply via email to