Update of /var/cvs/src/org/mmbase/util
In directory james.mmbase.org:/tmp/cvs-serv11334

Modified Files:
        ResourceLoader.java 
Log Message:
sigh


See also: http://cvs.mmbase.org/viewcvs/src/org/mmbase/util


Index: ResourceLoader.java
===================================================================
RCS file: /var/cvs/src/org/mmbase/util/ResourceLoader.java,v
retrieving revision 1.64
retrieving revision 1.65
diff -u -b -r1.64 -r1.65
--- ResourceLoader.java 21 Jul 2008 13:07:38 -0000      1.64
+++ ResourceLoader.java 21 Jul 2008 13:32:37 -0000      1.65
@@ -97,7 +97,7 @@
  * <p>For property-files, the java-unicode-escaping is undone on loading, and 
applied on saving, so there is no need to think of that.</p>
  * @author Michiel Meeuwissen
  * @since  MMBase-1.8
- * @version $Id: ResourceLoader.java,v 1.64 2008/07/21 13:07:38 michiel Exp $
+ * @version $Id: ResourceLoader.java,v 1.65 2008/07/21 13:32:37 michiel Exp $
  */
 public class ResourceLoader extends ClassLoader {
 
@@ -980,8 +980,10 @@
                     return con.getURL();
                 }
             } else if (cf instanceof AbstractFileURLStreamHandler) {
-                FileConnection con = (FileConnection) cf.openConnection(name);
-                File file = con.getFile();
+                URLConnection con = cf.openConnection(name);
+                if (con instanceof FileConnection) { // could be NOT AVAILABLE
+                    FileConnection fc = (FileConnection) con;
+                    File file = fc.getFile();
                 if (file.equals(f)) {
                     return null; // ok, not shadowed.
                 } else {
@@ -995,6 +997,7 @@
                 }
             }
         }
+        }
         for (File file : getFiles(name)) {
             if (file.equals(f)) {
                 return null;
_______________________________________________
Cvs mailing list
[email protected]
http://lists.mmbase.org/mailman/listinfo/cvs

Reply via email to