commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject cvs commit: jakarta-commons/latka/src/java/org/apache/commons/latka LatkaProperties.java
Date Sun, 08 Dec 2002 12:58:38 GMT
dion        2002/12/08 04:58:38

  Modified:    latka/src/java/org/apache/commons/latka LatkaProperties.java
  Log:
  There may not be a context class loader
  
  Revision  Changes    Path
  1.14      +4 -0      jakarta-commons/latka/src/java/org/apache/commons/latka/LatkaProperties.java
  
  Index: LatkaProperties.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/latka/src/java/org/apache/commons/latka/LatkaProperties.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -r1.13 -r1.14
  --- LatkaProperties.java	14 Jul 2002 16:41:38 -0000	1.13
  +++ LatkaProperties.java	8 Dec 2002 12:58:38 -0000	1.14
  @@ -181,6 +181,10 @@
           Properties properties  = new Properties();
       
           ClassLoader loader = Thread.currentThread().getContextClassLoader();
  +        if (loader == null) {
  +        	// there may not be a context class loader
  +        	loader = LatkaProperties.class.getClassLoader();
  +        }
   
           InputStream stream = loader.getResourceAsStream(classpathLocation);
   
  
  
  

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


Mime
View raw message