Community
Participate
Working Groups
Build Identifier: I20120518-2145 Our plugin crashes on Eclipse 4.2 (and probably 3.8) when we call setListElements(), with this exception: java.lang.NullPointerException at org.eclipse.ui.dialogs.AbstractElementListSelectionDialog.handleElementsChanged(AbstractElementListSelectionDialog.java:190) at org.eclipse.ui.dialogs.AbstractElementListSelectionDialog.setListElements(AbstractElementListSelectionDialog.java:179) at This is because setListElements() calls handleElementsChanged() which looks like this: protected void handleElementsChanged() { boolean enabled = !fFilteredList.isEmpty(); fMessage.setEnabled(enabled); <============ We hit an NPE here because fMessage is null in our case. We don't call createMessageArea() when creating our dialog; we put various other controls (radio buttons if I recall correctly) in the message area instead. I can work around this (by calling the method and then making the label invisible), but this is likely a compatibility bug which might affect others as well, so it's probably better if you add a null check on the above field access. Reproducible: Always Steps to Reproduce: This bug was originally filed against the Android Eclipse plugin, and the exact steps to reproduce are listed there: http://code.google.com/p/android/issues/detail?id=32527
Created attachment 217650 [details] Add a null (and disposed check)
Sorry, didn't check the patch close enough...;~). This fix will be in the maintenance release.
(In reply to comment #2) > Sorry, didn't check the patch close enough...;~). > > This fix will be in the maintenance release. Should this bug be marked FIXED?
Yes, it's been released.