aboutsummaryrefslogtreecommitdiff
path: root/libjava/java/net
diff options
context:
space:
mode:
authorBryce McKinlay <bryce@waitaki.otago.ac.nz>2001-09-30 07:52:16 +0000
committerBryce McKinlay <bryce@gcc.gnu.org>2001-09-30 08:52:16 +0100
commit218e1e912d74b89f0a6bd7c694bdc89c4515610b (patch)
treecee5ad8e6a313b1e905f67f99992217b06f84001 /libjava/java/net
parentfa8290383271f5131ea04a917cb130e116150538 (diff)
downloadgcc-218e1e912d74b89f0a6bd7c694bdc89c4515610b.zip
gcc-218e1e912d74b89f0a6bd7c694bdc89c4515610b.tar.gz
gcc-218e1e912d74b89f0a6bd7c694bdc89c4515610b.tar.bz2
re PR libgcj/4383 (file: protocol not supported in URLConnection?)
PR libgcj/4383 * gnu/gcj/protocol/file/Connection.java (connect): Throw FileNotFoundException if appropriate. * gnu/gcj/protocol/file/Handler.java (openConnection): Throw an IOException if we got a file: url with a hostname. Comment out protocol switch to ftp for now. * java/net/URL.java (URL): Include protocol name in exception message when handler can't be found. From-SVN: r45898
Diffstat (limited to 'libjava/java/net')
-rw-r--r--libjava/java/net/URL.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/libjava/java/net/URL.java b/libjava/java/net/URL.java
index 25291fa..636e6ef 100644
--- a/libjava/java/net/URL.java
+++ b/libjava/java/net/URL.java
@@ -76,7 +76,7 @@ public final class URL implements Serializable
this.handler = setURLStreamHandler(protocol);
if (this.handler == null)
- throw new MalformedURLException("Handler for protocol not found");
+ throw new MalformedURLException("Protocol handler not found: " + protocol);
this.host = host;
@@ -175,7 +175,7 @@ public final class URL implements Serializable
this.handler = setURLStreamHandler(protocol);
if (this.handler == null)
- throw new MalformedURLException("Handler for protocol not found");
+ throw new MalformedURLException("Protocol handler not found: " + protocol);
// JDK 1.2 doc for parseURL specifically states that any '#' ref
// is to be excluded by passing the 'limit' as the indexOf the '#'