United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-8000555 BasicService.showDocument() API fails to launch the browser in Windows XP
JDK-8000555 : BasicService.showDocument() API fails to launch the browser in Windows XP

Details
Type:
Bug
Submit Date:
2012-10-08
Status:
Resolved
Updated Date:
2014-02-12
Project Name:
JDK
Resolved Date:
2013-07-02
Component:
deploy
OS:
windows_xp
Sub-Component:
webstart
CPU:
x86
Priority:
P2
Resolution:
Fixed
Affected Versions:
6u34,7u6
Fixed Versions:
7u60 (b01)

Related Reports
Backport:
Backport:
Backport:
Backport:

Sub Tasks

Description
The issue is that BasicService.showDocument() API fails to launch the browser in Windows XP. This is reproducible with the test case below and also it is reproducible in both Java6 and Java7
                                    

Comments
The issue is that the URL length exceeds internal buffer size which is used by ShellExecute on Windows XP.

The attached applet dynamically constructs URL from 3 parts. CONST1+URLREWRITE+CONST2. To get URLREWRITE part the applet makes a call to the server and uses it response to produce it. On jre8 this call during getting URLREWRITE part fails witth IllegalState exception so URLREWRITE becomes an  empty string as a result the whole URL becomes shorter and ShellExecute works fine in that case.

The proper fix could be to detects such case and create a temporary Internet shortcut file that contains the long URL and pass the Internet shortcut file to ShellExecute.
                                     
2013-06-10
SQE-OK to get the issue fixed for 7u40.
                                     
2013-07-03
justification:  showdocument does not work in windows XP.  low risk fix and only affects XP case.  showdocument is a popular API.
                                     
2013-07-03
Reproducible test case 
                                     
2012-10-09
Readme txt file to execute the test case
                                     
2012-10-09
Cannot reproduce on latest Java 8 (1.8.0-ea-b92) build
Reproduced on Java 7 u25
Reproduced on Java 7 u40-ea-b28
                                     
2013-06-06



Hardware and Software, Engineered to Work Together