WTK http stack implementation bug: malformed URL

Hi

the WTK emulators dont parse URLs correctly. The following code throws an "java.lang.IllegalArgumentException: malformed URL" exception. It works on most phones and the SonyEricsson J2ME SDK tho.

c = (HttpConnection) Connector.open("http://www.4950.net");

The stack trace is

java.lang.IllegalArgumentException: malformed URL

at com.sun.midp.io.HttpUrl.isIPv4Address(+88)

at com.sun.midp.io.HttpUrl.parseAfterScheme(+568)

at com.sun.midp.io.HttpUrl.<init>(+36)

at com.sun.midp.io.j2me.http.Protocol.connect(+18)

at com.sun.midp.io.ConnectionBaseAdapter.openPrim(+52)

at javax.microedition.io.Connector.openPrim(+299)

at javax.microedition.io.Connector.open(+15)

at javax.microedition.io.Connector.open(+6)

at javax.microedition.io.Connector.open(+5)

I interpret the error as the http stacks recognizing this url as a numbered notation (e.g. http://123.234.34.24) instead of a text notation (e.g. http://www.google.com).

I tried to look into the midp sources but the ones that are online do not contain the method com.sun.midp.io.HttpUrl.isIPv4Address from reading the source available it seems that the midp2.0fcs sources dont contain this error.

Can anyone in sun fix this?

[1286 byte] By [Raienra] at [2007-11-27 6:26:20]
# 1
an URL cannot start with a number after the www !
suparenoa at 2007-7-12 17:47:05 > top of Java-index,Java Mobility Forums,Java ME Technologies...