From: Tom Tromey Date: Wed, 12 Sep 2001 04:28:32 +0000 (+0000) Subject: * java/io/File.java (toURL): Use getAbsolutePath and `file://'. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=45571704cf28ce7a22e5d88318f46c369cf9e148;p=gcc.git * java/io/File.java (toURL): Use getAbsolutePath and `file://'. From-SVN: r45556 --- diff --git a/libjava/ChangeLog b/libjava/ChangeLog index 85631936032..72ee2b10665 100644 --- a/libjava/ChangeLog +++ b/libjava/ChangeLog @@ -1,3 +1,7 @@ +2001-09-11 Tom Tromey + + * java/io/File.java (toURL): Use getAbsolutePath and `file://'. + 2001-09-10 Tom Tromey * java/util/Properties.java (load): Correctly read \u sequences. diff --git a/libjava/java/io/File.java b/libjava/java/io/File.java index 12297acc4ae..3ecd7bf037d 100644 --- a/libjava/java/io/File.java +++ b/libjava/java/io/File.java @@ -281,7 +281,8 @@ public class File implements Serializable, Comparable public URL toURL () throws MalformedURLException { - return new URL ("file:" + path + (isDirectory() ? "/" : "")); + return new URL ("file://" + getAbsolutePath () + + (isDirectory() ? "/" : "")); } private final native boolean performMkdir ();