JDK-7015261 : FileDialog.getLocationOnScreen throws NPE on Win
  • Type: Bug
  • Component: client-libs
  • Sub-Component: java.awt
  • Affected Version: 7
  • Priority: P2
  • Status: Closed
  • Resolution: Duplicate
  • OS: windows_7
  • CPU: x86
  • Submitted: 2011-01-27
  • Updated: 2011-01-27
  • Resolved: 2011-01-27
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
7Resolved
Related Reports
Duplicate :  
Description
FileDialog.getLocationOnScreen throws NPE on Win. Simple test attached. Issue is reproducible on JDK 7 b120, JDK1.6.0_22 on Win7, WinXP.

Test output:
java version "1.6.0_22"
Java(TM) SE Runtime Environment (build 1.6.0_22-b04)
Java HotSpot(TM) Client VM (build 17.1-b03, mixed mode, sharing)
Exception in thread "main" java.lang.NullPointerException: null pData
        at sun.awt.windows.WComponentPeer.getLocationOnScreen(Native Method)
        at java.awt.Component.getLocationOnScreen_NoTreeLock(Component.java:1939)
        at java.awt.Component.getLocationOnScreen(Component.java:1917)
        at FileDialogTest.main(FileDialogTest.java:30)

On Solaris and OEL5.5 that method works, but returns wrong value.