JDK-7073628 : DT: message boxes shouldn't be shown during JRE/FX installation if javascript callback is used
  • Type: Bug
  • Component: deploy
  • Sub-Component: deployment_toolkit
  • Affected Version: 7-client
  • Priority: P3
  • Status: Closed
  • Resolution: Fixed
  • OS: windows_xp
  • CPU: x86
  • Submitted: 2011-08-01
  • Updated: 2011-11-28
  • Resolved: 2011-11-28
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 7 JDK 8
7u2 b03Fixed 8Fixed
Related Reports
Relates :  
Description
Fix for 7052499 allows DT to callback to a javascript function to report JRE and FX installation status. This CR is to prevent the existing message boxes from being shown if javascript callback is used during installation.

Comments
EVALUATION A fix is to add a isSilentErrors() method in the IntallCallback class. The method returns true if either the silent flag is set or a javascript callback is defined. JREInstall.install() and JavaFX.install() calls the isSilentErrors and display MessageBox if the method returns false. This webrev also contains the following fixes: 1) FF crash crash on reload which the download FX dialog is being displayed The cause is that the mNPP became invalid inside NotifyInstallStatus when calling pluginThreadAysncCall. Fix is to set the mNPP to NULL in ~ScriptablePluginObject() within a critical section. In NotifyInstallStatus, null check mNPP inside the same critical section and call pluginThreadAsyncCall if it isn't null. 2) Forgot to report status upon cancel on download. Fixed in JREInstall.install() and JavaFX.install(). There's no issue with the FX download thread. The onOk and onCancel methods in CDownloadDialog are synchronized with the download thread. 3) Missing install status sometimes. The problem is due to synchronization issue between pluginThreadCallback and NotifyInstallStatus in ScriptablePluginObject. NPN_InvokeDefault fails sometimes if NotifyInstallStatus returns too soon. By the time pluginThreadCallback is invoked, the NPObject may become invalid if the destructor of MozInstallCallback has been invoked. A fix is to add a handle to synchronize the pluginThreadCallback and NotifyInstallStatus methods. NotifyInstallStatus will wait for pluginThreadCallback to finish and then release the allocated resources including the handle.
16-08-2011