<AWT Dev> [9] Review request for 8064934: Incorrect Exception message from java.awt.Desktop.open()

dmitry markov dmitry.markov at oracle.com
Fri Jan 23 12:00:23 UTC 2015


Hello,

Could you review the fix for jdk9, please?

     bug: https://bugs.openjdk.java.net/browse/JDK-8064934
     webrev: http://cr.openjdk.java.net/~dmarkov/8064934/jdk9/webrev.00/

Problem description: in Java_sun_awt_windows_WDesktopPeer_ShellExecute() 
we pass to FormatMessage() the error code returned by ShellExecute() 
function. This is not correct, since error codes returned by 
ShellExecute() are not covered by System Error Codes. As a result we get 
incorrect error message from java.awt.Desktop.open().
Fix: we have to pass to FormatMessage() the error code returned by 
GetLastError() function instead of code returned by ShellExecute().

Thanks,
Dmitry


More information about the awt-dev mailing list