Community
Participate
Working Groups
In class org.eclipse.jface.action.StatusLine, method SubTask(String name) NPE. StatusLine.subTask(String) line: 552 StatusLineManager$1.subTask(String) line: 205 EventLoopProgressMonitor(ProgressMonitorWrapper).subTask(String) line: 154 EventLoopProgressMonitor.subTask(String) line: 171 SBModelManager.saveModelState(IProject, IProgressMonitor) line: 175 It happens if beginTask method was never called before. I think it is better to check fTaskName.
changing prio and status per platform ui bug guidelines
Created attachment 112768 [details] One Line fix for NPE in #subTask(String) This is still a problem in 3.4 (build I20080617-2000). It can be reproduced by calling StatusLine#subTask(String) before calling something that sets the task name (ie: #beginTask(String,int)). The fix to bug 162140 (https://bugs.eclipse.org/bugs/show_bug.cgi?id=162140) got most of the cases for setting fTaskName to null, but missed this check. java.lang.NullPointerException at org.eclipse.jface.action.StatusLine.subTask(StatusLine.java:619) at org.eclipse.jface.action.StatusLineManager$1.subTask(StatusLineManager.java:207) at com.ibm.wrath.progress.WalkbackProgressMonitor.subTask(WalkbackProgressMonitor.java:89) at com.ibm.wrath.progress.WrathProgressMonitor.handleUpdateProgress(WrathProgressMonitor.java:51) at com.ibm.wrath.progress.WrathProgressEventHandler.handleRequest(WrathProgressEventHandler.java:75) at com.ibm.wrath.communication.client.WrathAsyncListener$HandleJob.run(WrathAsyncListener.java:198) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
thanks for the patch, marking for M3.
committed patch to HEAD >20081024
verified WinXP, Build id: I20081027-1800 using local snippet ApplicationWindowProgressTest