Hi,

I'm concerned about the result of getHost() on a java.net.URL, when there is no host part in the URL. Unfortunately the Sun's javadoc is not clear in this case (while it is in this case for getFile -- empty string -- and getRef -- null). However, both Sun and gcj/gij agree on returnin an empty string. It would be nice if Kaffe could do the same instead of returning null. (Is this a part that is not merged yes with Classpath?).

I attach a testcase.

Cheers,

Daniel

import java.net.*;

public class URLHost
{
  public static void main(String[] args) throws MalformedURLException
  {
    URL url = new URL("jar:file://root/my.jar!/");

    System.out.println("Host: " + url.getHost());
  }
}
_______________________________________________
kaffe mailing list
[EMAIL PROTECTED]
http://kaffe.org/cgi-bin/mailman/listinfo/kaffe

Reply via email to