Community
Participate
Working Groups
To reproduce, bring up a histogram then in the <Numeric> space type some letters or >ABC java.lang.NullPointerException at org.eclipse.mat.query.refined.Filter$NumericFilter.number(Filter.java:225) at org.eclipse.mat.query.refined.Filter$NumericFilter.setCriteria(Filter.java:200) at org.eclipse.mat.ui.internal.viewer.RefinedResultViewer$18.updateCriteria(RefinedResultViewer.java:1014) at org.eclipse.mat.ui.internal.viewer.RefinedResultViewer$18.handleEvent(RefinedResultViewer.java:1000) at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:938) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:962) at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:947) at org.eclipse.swt.widgets.Control.traverse(Control.java:3385) at org.eclipse.swt.widgets.Control.translateTraversal(Control.java:3367) at org.eclipse.swt.widgets.Display.translateTraversal(Display.java:4204) at org.eclipse.swt.widgets.Display.filterMessage(Display.java:1155) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3289) at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2389) at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2353) at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2219) at org.eclipse.ui.internal.Workbench$4.run(Workbench.java:466) at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:289) at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:461) at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149) at org.eclipse.mat.ui.rcp.Application.start(Application.java:26) at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:169) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:106) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:76) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:363) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:176) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:48) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37) at java.lang.reflect.Method.invoke(Method.java:600) at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:508) at org.eclipse.equinox.launcher.Main.basicRun(Main.java:447) at org.eclipse.equinox.launcher.Main.run(Main.java:1173) at org.eclipse.equinox.launcher.Main.main(Main.java:1148)
The fix is trivial - in Filter.java the parse method can return null, so the success should be checked before converting to a double.
Fix is to parse the Number, check the parse was successful, and only convert the Number (not null) to a double if successful.