From 45571704cf28ce7a22e5d88318f46c369cf9e148 Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Wed, 12 Sep 2001 04:28:32 +0000 Subject: * java/io/File.java (toURL): Use getAbsolutePath and `file://'. From-SVN: r45556 --- libjava/java/io/File.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'libjava/java') diff --git a/libjava/java/io/File.java b/libjava/java/io/File.java index 12297ac..3ecd7bf 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 (); -- cgit v1.1