MalformedURLException in XP version of Safari

User 08353716d8

06-06-2011 18:28:12

Hi,


I understand that MarvinSketch is not supported in the Windows version of Safari 5, but I thought I'd ask here just to make sure there isn't some fix out there. When opening MarvinSketch applet version 5.4.1.1 in Safari 5 on XP yields the following error in the console on startup:


 


java.net.MalformedURLException: no protocol:
at java.net.URL.<init>(Unknown Source)
at java.net.URL.<init>(Unknown Source)
at java.net.URL.<init>(Unknown Source)
at sun.plugin.liveconnect.SecureInvocation.checkLiveConnectCaller(Unknown Source)
at sun.plugin.liveconnect.SecureInvocation.access$000(Unknown Source)
at sun.plugin.liveconnect.SecureInvocation$2.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at sun.plugin.liveconnect.SecureInvocation.CallMethod(Unknown Source)


 


Later in the process, we're calling getMol on the applet and closing its containing window - a value is returned, but somewhere in the process, something chokes and Safari crashes altogether. Opening the applet in Firefox/IE on XP work fine, no errors in the console on startup, no crash on getMol/close.


If the answer to this is the fact that MarvinSketch applets aren't supported in the Windows versions of Safari, that's fine, I just wanted to verify that there isn't a workaround.


Thanks ahead of time for any clarification.


Danny Holyfield
Application Developer
WebAssign

ChemAxon 7c2d26e5cf

09-06-2011 15:06:50

We have not tested Safari 5 under Windows XP yet.


We will complete it soon.


I have installed it on a Windows XP machine. It seems Safari can display the applet.


Indeed, there is an error message on the console. We will check what cause the problem and it causes any limitation in the usability.

User 08353716d8

09-06-2011 15:10:45

Safari does disaply the applet for us, and it seems to operate fine, up until the point we call getMol and close the containing window/page. At that point, Safari crashes. Let us know when the error on startup is cleared up and we'll see if that fixes the crashing problem (hopefully the two are related).


thanks for taking a look at this.


 


Danny Holyfield


Application Developer


WebAssign

ChemAxon 7c2d26e5cf

15-06-2011 13:11:11

As I see, get/setMol is OK. This example works fine in Safari.


http://www.chemaxon.com/marvin/examples/applets/sketch/js_io.html


Can you show a simple example where this issue is reproducable?


The clue of the issue may be at window closing.


Have you tried to switch off legacy_lifecycle support by the legacy_lifecycle applet parameter? It determine how to handle applet after leaving page/closing window.

ChemAxon 7c2d26e5cf

21-06-2011 13:25:47

It seems to be a Windows specific Java issue. All Java applets (not only ChemAxon ones) throw this exception in Safari for Windows.


Several developers complains about this Safari bug on various forums. But I have not found any workaround in these topics.


http://stackoverflow.com/questions/308305/differences-between-safari-for-windows-and-safari-for-mac


http://forums.oracle.com/forums/thread.jspa?messageID=5462597


https://discussions.apple.com/thread/2612951?threadID=2612951


Anyway, I have created a dummy applet (see attachment) that prints some info. The MalformedURLException can be reproduced with this example too.


Compile the attached java source and open the given html document in Safari under Windows to test it.