classpath-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[cp-patches] FYI: Better MalformedURLException


From: Mark Wielaard
Subject: [cp-patches] FYI: Better MalformedURLException
Date: Sat, 23 Apr 2005 15:05:15 +0200

Hi,

The following helped me a lot with debugging some URL problem.
It simply adds the spec to parse as URL to the MalformedURLException of
the URL constructor when there is a null context.

2005-04-23  Mark Wielaard  <address@hidden>

       * java/net/URL.java (URL(URL,String,URLStreamHandler)): Add spec
       to MalformedURLException.

Committed,

Mark
? java/net/URL.mark
Index: java/net/URL.java
===================================================================
RCS file: /cvsroot/classpath/classpath/java/net/URL.java,v
retrieving revision 1.45
diff -u -r1.45 URL.java
--- java/net/URL.java   19 Apr 2005 01:09:26 -0000      1.45
+++ java/net/URL.java   23 Apr 2005 13:02:26 -0000
@@ -430,7 +430,8 @@
        authority = context.authority;
       }
     else // Protocol NOT specified in spec. and no context available.
-      throw new MalformedURLException("Absolute URL required with null 
context");
+      throw new MalformedURLException("Absolute URL required with null"
+                                     + " context: " + spec);
 
     protocol = protocol.trim();
 

Attachment: signature.asc
Description: This is a digitally signed message part


reply via email to

[Prev in Thread] Current Thread [Next in Thread]