JDK-7021689 : [ja] Notepad demo throws NPE
  • Type: Bug
  • Component: globalization
  • Sub-Component: translation
  • Affected Version: 7
  • Priority: P3
  • Status: Closed
  • Resolution: Fixed
  • OS: linux_redhat_5.0
  • CPU: x86
  • Submitted: 2011-02-23
  • Updated: 2011-04-26
  • Resolved: 2011-04-26
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
7 b138Fixed
Related Reports
Relates :  
Relates :  
Description
JDK bundled demo demo/jfc/Notepad throws exception when executed under ja locale. The demo is localized into ja, sv, and zh_CN and only ja seems to have problem.

bash-3.2$ export LANG=ja_JP.UTF-8
bash-3.2$ export LC_ALL=$LANG
bash-3.2$ java -jar Notepad.jar
uncaught exception: java.lang.NullPointerException
java.lang.NullPointerException
        at javax.swing.ImageIcon.<init>(ImageIcon.java:187)
        at Notepad.createToolbarButton(Notepad.java:330)
        at Notepad.createTool(Notepad.java:316)
        at Notepad.createToolbar(Notepad.java:305)
        at Notepad.<init>(Notepad.java:120)
        at Notepad.main(Notepad.java:140)

Tested using promoted jdk7 b130.

Comments
EVALUATION Fixed in b138.
09-04-2011

EVALUATION I will retarget this CR to b138 to be fixed in message drop 2. The t13y fix has been filed and fixed as a new bug 7025267.
07-03-2011

EVALUATION I will update jdk/src/share/demo/jfc/Notepad/resources/Notepad.properties with comments to not translate non-translatable strings.
01-03-2011