Index: java/org/apache/ivy/plugins/repository/ResourceHelper.java
===================================================================
--- java/org/apache/ivy/plugins/repository/ResourceHelper.java	(revision 680328)
+++ java/org/apache/ivy/plugins/repository/ResourceHelper.java	(working copy)
@@ -41,7 +41,7 @@
             return new File(res.getName()).equals(f);
         } else if (res instanceof URLResource) {
             try {
-                return f.toURL().toExternalForm().equals(res.getName());
+                return f.toURI().toURL().toExternalForm().equals(res.getName());
             } catch (MalformedURLException e) {
                 return false;
             }
Index: java/org/apache/ivy/plugins/resolver/RepositoryResolver.java
===================================================================
--- java/org/apache/ivy/plugins/resolver/RepositoryResolver.java	(revision 680328)
+++ java/org/apache/ivy/plugins/resolver/RepositoryResolver.java	(working copy)
@@ -100,7 +100,7 @@
                             ModuleDescriptorParser parser = 
                                 ModuleDescriptorParserRegistry.getInstance().getParser(res);
                             ModuleDescriptor md = 
-                                parser.parseDescriptor(getSettings(), temp.toURL(), res, false);
+                                parser.parseDescriptor(getSettings(), temp.toURI().toURL(), res, false);
                             revision = md.getRevision();
                             if ((revision == null) || (revision.length() == 0)) {
                                 revision = "working@" + name;
Index: java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorUpdater.java
===================================================================
--- java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorUpdater.java	(revision 680328)
+++ java/org/apache/ivy/plugins/parser/xml/XmlModuleDescriptorUpdater.java	(working copy)
@@ -133,7 +133,7 @@
             if (res instanceof URLResource) {
                 inputStreamContext = ((URLResource) res).getURL();
             } else if (res instanceof FileResource) {
-                inputStreamContext = ((FileResource) res).getFile().toURL();
+                inputStreamContext = ((FileResource) res).getFile().toURI().toURL();
             }
             update(inputStreamContext, in, fos, options);
         } finally {
@@ -445,7 +445,7 @@
                         String urlStr = attributes.getValue("url");
                         url = new URL(urlStr);
                     } else {
-                        url = new File(fileName).toURL();
+                        url = new File(fileName).toURI().toURL();
                     }
                 }
                 XMLHelper.parse(url, null, new DefaultHandler() {
Index: java/org/apache/ivy/ant/IvyCheck.java
===================================================================
--- java/org/apache/ivy/ant/IvyCheck.java	(revision 680328)
+++ java/org/apache/ivy/ant/IvyCheck.java	(working copy)
@@ -72,7 +72,7 @@
         try {
             Ivy ivy = getIvyInstance();
             if (file != null) {
-                if (ivy.check(file.toURL(), resolvername)) {
+                if (ivy.check(file.toURI().toURL(), resolvername)) {
                     Message.verbose("checked " + file + ": OK");
                 }
             }
@@ -85,7 +85,7 @@
                 String[] srcFiles = ds.getIncludedFiles();
                 for (int j = 0; j < srcFiles.length; j++) {
                     File file = new File(fromDir, srcFiles[j]);
-                    if (ivy.check(file.toURL(), resolvername)) {
+                    if (ivy.check(file.toURI().toURL(), resolvername)) {
                         Message.verbose("checked " + file + ": OK");
                     }
                 }
Index: java/org/apache/ivy/ant/IvyMakePom.java
===================================================================
--- java/org/apache/ivy/ant/IvyMakePom.java	(revision 680328)
+++ java/org/apache/ivy/ant/IvyMakePom.java	(working copy)
@@ -102,7 +102,7 @@
                 throw new BuildException("destination pom file is required for makepom task");
             }
             ModuleDescriptor md = XmlModuleDescriptorParser.getInstance().parseDescriptor(
-                getSettings(), ivyFile.toURL(), false);
+                getSettings(), ivyFile.toURI().toURL(), false);
             PomModuleDescriptorWriter.write(md,
                 headerFile == null ? null : FileUtil.readEntirely(getHeaderFile()),
                 mappings.isEmpty() 
Index: java/org/apache/ivy/ant/IvyBuildList.java
===================================================================
--- java/org/apache/ivy/ant/IvyBuildList.java	(revision 680328)
+++ java/org/apache/ivy/ant/IvyBuildList.java	(working copy)
@@ -205,7 +205,7 @@
                 } else {
                     try {
                         ModuleDescriptor md = ModuleDescriptorParserRegistry.getInstance()
-                                .parseDescriptor(settings, ivyFile.toURL(), doValidate(settings));
+                                .parseDescriptor(settings, ivyFile.toURI().toURL(), doValidate(settings));
                         buildFiles.put(md, buildFile);
                         mds.add(md);
                         Message.debug("Add " + md.getModuleRevisionId().getModuleId());
Index: java/org/apache/ivy/ant/IvyConvertPom.java
===================================================================
--- java/org/apache/ivy/ant/IvyConvertPom.java	(revision 680328)
+++ java/org/apache/ivy/ant/IvyConvertPom.java	(working copy)
@@ -60,9 +60,9 @@
                 throw new BuildException("destination ivy file is required for convertpom task");
             }
             ModuleDescriptor md = PomModuleDescriptorParser.getInstance().parseDescriptor(
-                getSettings(), pomFile.toURL(), false);
-            PomModuleDescriptorParser.getInstance().toIvyFile(pomFile.toURL().openStream(),
-                new URLResource(pomFile.toURL()), getIvyFile(), md);
+                getSettings(), pomFile.toURI().toURL(), false);
+            PomModuleDescriptorParser.getInstance().toIvyFile(pomFile.toURI().toURL().openStream(),
+                new URLResource(pomFile.toURI().toURL()), getIvyFile(), md);
         } catch (MalformedURLException e) {
             throw new BuildException("unable to convert given pom file to url: " + pomFile + ": "
                     + e, e);
Index: java/org/apache/ivy/ant/IvyResolve.java
===================================================================
--- java/org/apache/ivy/ant/IvyResolve.java	(revision 680328)
+++ java/org/apache/ivy/ant/IvyResolve.java	(working copy)
@@ -229,7 +229,7 @@
                 if (file == null) {
                     file = getProject().resolveFile(getProperty(settings, "ivy.dep.file"));
                 }
-                report = ivy.resolve(file.toURL(), getResolveOptions(ivy, confs, settings));
+                report = ivy.resolve(file.toURI().toURL(), getResolveOptions(ivy, confs, settings));
             }
             if (report.hasError()) {
                 if (failureProperty != null) {
Index: java/org/apache/ivy/ant/IvyInfo.java
===================================================================
--- java/org/apache/ivy/ant/IvyInfo.java	(revision 680328)
+++ java/org/apache/ivy/ant/IvyInfo.java	(working copy)
@@ -133,7 +133,7 @@
                     file = getProject().resolveFile(getProperty(settings, "ivy.dep.file"));
                 }
                 ModuleDescriptor md = ModuleDescriptorParserRegistry.getInstance().parseDescriptor(
-                    settings, file.toURL(), doValidate(settings));
+                    settings, file.toURI().toURL(), doValidate(settings));
                 ModuleRevisionId mrid = md.getModuleRevisionId();
                 setProperties(md, mrid);
             }
Index: java/org/apache/ivy/Main.java
===================================================================
--- java/org/apache/ivy/Main.java	(revision 680328)
+++ java/org/apache/ivy/Main.java	(working copy)
@@ -228,7 +228,7 @@
             }
             ResolveOptions resolveOptions = new ResolveOptions().setConfs(confs)
                 .setValidate(validate);
-            ResolveReport report = ivy.resolve(ivyfile.toURL(), resolveOptions);
+            ResolveReport report = ivy.resolve(ivyfile.toURI().toURL(), resolveOptions);
             if (report.hasError()) {
                 System.exit(1);
             }
@@ -416,7 +416,7 @@
             for (Iterator iter = fileList.iterator(); iter.hasNext();) {
                 File file = (File) iter.next();
                 try {
-                    urls.add(file.toURL());
+                    urls.add(file.toURI().toURL());
                 } catch (MalformedURLException e) {
                     // Should not happen, just ignore.
                 } 
@@ -438,7 +438,7 @@
                 ArtifactDownloadReport artifact = (ArtifactDownloadReport) iter.next();
 
                 if (artifact.getLocalFile() != null) {
-                    urls.add(artifact.getLocalFile().toURL());
+                    urls.add(artifact.getLocalFile().toURI().toURL());
                 }
             }
         } catch (Exception ex) {
Index: java/org/apache/ivy/core/resolve/ResolveEngine.java
===================================================================
--- java/org/apache/ivy/core/resolve/ResolveEngine.java	(revision 680328)
+++ java/org/apache/ivy/core/resolve/ResolveEngine.java	(working copy)
@@ -128,7 +128,7 @@
     }
 
     public ResolveReport resolve(File ivySource) throws ParseException, IOException {
-        return resolve(ivySource.toURL());
+        return resolve(ivySource.toURI().toURL());
     }
 
     public ResolveReport resolve(URL ivySource) throws ParseException, IOException {
Index: java/org/apache/ivy/core/retrieve/RetrieveEngine.java
===================================================================
--- java/org/apache/ivy/core/retrieve/RetrieveEngine.java	(revision 680328)
+++ java/org/apache/ivy/core/retrieve/RetrieveEngine.java	(working copy)
@@ -202,7 +202,7 @@
             try {
                 File ivyFile = getCache().getResolvedIvyFileInCache(mrid);
                 Message.verbose("no explicit confs given for retrieve, using ivy file: " + ivyFile);
-                URL ivySource = ivyFile.toURL();
+                URL ivySource = ivyFile.toURI().toURL();
                 URLResource res = new URLResource(ivySource);
                 ModuleDescriptorParser parser = ModuleDescriptorParserRegistry.getInstance()
                         .getParser(res);
Index: java/org/apache/ivy/core/deliver/DeliverEngine.java
===================================================================
--- java/org/apache/ivy/core/deliver/DeliverEngine.java	(revision 680328)
+++ java/org/apache/ivy/core/deliver/DeliverEngine.java	(working copy)
@@ -115,7 +115,7 @@
         ModuleDescriptor md = null;
         URL ivyFileURL = null;
         try {
-            ivyFileURL = ivyFile.toURL();
+            ivyFileURL = ivyFile.toURI().toURL();
             md = XmlModuleDescriptorParser.getInstance().parseDescriptor(settings, ivyFileURL,
                 options.isValidate());
             md.setResolvedModuleRevisionId(ModuleRevisionId.newInstance(mrid, 
Index: java/org/apache/ivy/core/RelativeUrlResolver.java
===================================================================
--- java/org/apache/ivy/core/RelativeUrlResolver.java	(revision 680328)
+++ java/org/apache/ivy/core/RelativeUrlResolver.java	(working copy)
@@ -47,7 +47,7 @@
         if (file != null) {
             File f = new File(file);
             if (f.isAbsolute()) {
-                return f.toURL();
+                return f.toURI().toURL();
             } else {
                 return getURL(context, file);
             }
Index: java/org/apache/ivy/core/settings/IvySettings.java
===================================================================
--- java/org/apache/ivy/core/settings/IvySettings.java	(revision 680328)
+++ java/org/apache/ivy/core/settings/IvySettings.java	(working copy)
@@ -368,7 +368,7 @@
 
         loadDefaultProperties();
         try {
-            new XmlSettingsParser(this).parse(settingsFile.toURL());
+            new XmlSettingsParser(this).parse(settingsFile.toURI().toURL());
         } catch (MalformedURLException e) {
             IllegalArgumentException iae = new IllegalArgumentException(
                     "given file cannot be transformed to url: " + settingsFile);
@@ -458,7 +458,7 @@
             setDeprecatedVariable("ivy.conf.dir", "ivy.settings.dir");
             setVariable("ivy.settings.file", settingsFile.getAbsolutePath());
             setDeprecatedVariable("ivy.conf.file", "ivy.settings.file");
-            setVariable("ivy.settings.url", settingsFile.toURL().toExternalForm());
+            setVariable("ivy.settings.url", settingsFile.toURI().toURL().toExternalForm());
             setDeprecatedVariable("ivy.conf.url", "ivy.settings.url");
         } catch (MalformedURLException e) {
             IllegalArgumentException iae = new IllegalArgumentException(
Index: java/org/apache/ivy/core/settings/XmlSettingsParser.java
===================================================================
--- java/org/apache/ivy/core/settings/XmlSettingsParser.java	(revision 680328)
+++ java/org/apache/ivy/core/settings/XmlSettingsParser.java	(working copy)
@@ -454,7 +454,7 @@
                 throw new IllegalArgumentException(
                         "either url or file should be given for classpath element");
             } else {
-                url = new File(file).toURL();
+                url = new File(file).toURI().toURL();
             }
         } else {
             url = new URL(urlStr);
Index: java/org/apache/ivy/core/cache/DefaultRepositoryCacheManager.java
===================================================================
--- java/org/apache/ivy/core/cache/DefaultRepositoryCacheManager.java	(revision 680328)
+++ java/org/apache/ivy/core/cache/DefaultRepositoryCacheManager.java	(working copy)
@@ -543,7 +543,7 @@
                 // found in cache !
                 try {
                     ModuleDescriptor depMD = XmlModuleDescriptorParser.getInstance()
-                    .parseDescriptor(settings, ivyFile.toURL(), options.isValidate());
+                    .parseDescriptor(settings, ivyFile.toURI().toURL(), options.isValidate());
                     String resolverName = getSavedResolverName(depMD);
                     String artResolverName = getSavedArtResolverName(depMD);
                     DependencyResolver resolver = settings.getResolver(resolverName);
@@ -889,7 +889,7 @@
 
             URL cachedMDURL = null;
             try {
-                cachedMDURL = report.getLocalFile().toURL();
+                cachedMDURL = report.getLocalFile().toURI().toURL();
             } catch (MalformedURLException ex) {
                 Message.warn("malformed url exception for original in cache file: " 
                     + report.getLocalFile() + ": " + ex.getMessage());
Index: java/org/apache/ivy/core/publish/PublishEngine.java
===================================================================
--- java/org/apache/ivy/core/publish/PublishEngine.java	(revision 680328)
+++ java/org/apache/ivy/core/publish/PublishEngine.java	(working copy)
@@ -111,7 +111,7 @@
         ModuleDescriptor md = null;
         URL ivyFileURL = null;
         try {
-            ivyFileURL = ivyFile.toURL();
+            ivyFileURL = ivyFile.toURI().toURL();
             md = XmlModuleDescriptorParser.getInstance().parseDescriptor(settings, ivyFileURL,
                 false);
             if (options.getSrcIvyPattern() != null) {
@@ -138,7 +138,7 @@
                         ivyFile = tmp;
                         // we parse the new file to get updated module descriptor
                         md = XmlModuleDescriptorParser.getInstance().parseDescriptor(settings,
-                            ivyFile.toURL(), false);
+                            ivyFile.toURI().toURL(), false);
                         options.setSrcIvyPattern(ivyFile.getAbsolutePath());
                     } catch (SAXException e) {
                         throw new IllegalStateException("bad ivy file for " + mrid + ": " + ivyFile
