URL constructor URL(URL context, String spec) is getting failed with the following input on Solaris 8 with merlin build 42. Its working fine with Jdk1.3
URL context = new URL("http://a/b/c/d;p?q")
String spec = "../../../g"
How to reproduce this bug:
Run the following script to reproduce this script with merlin build 42.
import java.io.*;
import java.net.*;
public class TestParseURL {
public static void main(String[] arg) {
try {
String urlString = "http://a/b/c/d;p?q";
String urlspec = "../../../g";
System.out.println("url string" + urlString);
System.out.println("url spec " + urlspec);
URL context = new URL(urlString);
System.out.println("context " + context);
URL url = new URL(context , urlspec);
System.out.println("url string " + url.toString());
} catch(Exception exp) {
System.out.println(exp.getMessage());
}
}
} // End of class
Other Information:
Same code works with JDK1.3 on solaris 8 .
URL context = new URL("http://a/b/c/d;p?q")
String spec = "../../../g"
How to reproduce this bug:
Run the following script to reproduce this script with merlin build 42.
import java.io.*;
import java.net.*;
public class TestParseURL {
public static void main(String[] arg) {
try {
String urlString = "http://a/b/c/d;p?q";
String urlspec = "../../../g";
System.out.println("url string" + urlString);
System.out.println("url spec " + urlspec);
URL context = new URL(urlString);
System.out.println("context " + context);
URL url = new URL(context , urlspec);
System.out.println("url string " + url.toString());
} catch(Exception exp) {
System.out.println(exp.getMessage());
}
}
} // End of class
Other Information:
Same code works with JDK1.3 on solaris 8 .