From 005dd3d7d76686f9a289b2dc28208aa14f89433f Mon Sep 17 00:00:00 2001 From: ndw Date: Thu, 29 Sep 2005 11:21:06 +0000 Subject: [PATCH] Assure that filenames of the form c:/foo/bar and foo/bar don't get turned into inaccessible URIs of the form file://c:/foo/bar and file://foo/bar git-svn-id: https://svn.apache.org/repos/asf/xml/commons/trunk@292416 13f79535-47bb-0310-9956-ffa450edef68 --- java/src/org/apache/xml/resolver/helpers/FileURL.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/java/src/org/apache/xml/resolver/helpers/FileURL.java b/java/src/org/apache/xml/resolver/helpers/FileURL.java index 2622d52..017ab5e 100644 --- a/java/src/org/apache/xml/resolver/helpers/FileURL.java +++ b/java/src/org/apache/xml/resolver/helpers/FileURL.java @@ -77,9 +77,9 @@ public abstract class FileURL { userdir.replace('\\', '/'); if (userdir.endsWith("/")) { - return new URL("file://" + userdir + pathname); + return new URL("file:///" + userdir + pathname); } else { - return new URL("file://" + userdir + "/" + pathname); + return new URL("file:///" + userdir + "/" + pathname); } } }