The reference implementation of JOptionPane.showInputDialog() returns null when the user select the 'Cancel' option. Classpath cvs 2005.09.29 returns the current value of the input textfield, which makes it impossible to detect the 'Cancel' option. See attached testcase; the program should print 'Canceled!' when you press the 'Cancel' button.
Created attachment 9829 [details] testcase to demonstrate the bug
Fixed