Buggy code:
public class ProgressManager extends ProgressProvider implements IProgressService { public static final QualifiedName PROPERTY_IN_DIALOG = IProgressConstants . PROPERTY_IN_DIALOG ; private static ProgressManager singleton ; private final Map jobs = Collections . synchronizedMap ( new HashMap ( ) ) ; private final Map familyListeners = Collections . synchronizedMap ( new HashMap ( ) ) ; final Object familyKey = new Object ( ) ; private final Collection listeners = Collections . synchronizedList ( new ArrayList ( ) ) ; final ErrorNotificationManager errorManager = new ErrorNotificationManager ( ) ; IJobChangeListener changeListener ; static final String PROGRESS_VIEW_NAME = "org.eclipse.ui.views.ProgressView" ; static final String PROGRESS_FOLDER = "$nl$//icons//full//progress//" ; private static final String SLEEPING_JOB = "sleeping.gif" ; private static final String WAITING_JOB = "waiting.gif" ; private static final String BLOCKED_JOB = "lockedstate.gif" ; public static final String SLEEPING_JOB_KEY = "SLEEPING_JOB" ; public static final String WAITING_JOB_KEY = "WAITING_JOB" ; public static final String BLOCKED_JOB_KEY = "LOCKED_JOB" ; final Map runnableMonitors = Collections . synchronizedMap ( new HashMap ( ) ) ; final Object monitorKey = new Object ( ) ; private Hashtable imageKeyTable = new Hashtable ( ) ; private static final String IMAGE_KEY = "org.eclipse.ui.progress.images" ; public static ProgressManager getInstance ( ) { } public static void shutdownProgressManager ( ) { } class JobMonitor implements IProgressMonitorWithBlocking { Job job ; String currentTaskName ; IProgressMonitorWithBlocking listener ; JobMonitor ( Job newJob ) { } void addProgressListener ( IProgressMonitorWithBlocking monitor ) { } public void beginTask ( String taskName , int totalWork ) { } public void done ( ) { } public void internalWorked ( double work ) { } public boolean isCanceled ( ) { } public void setCanceled ( boolean value ) { } public void setTaskName ( String taskName ) { } public void subTask ( String name ) { } public void worked ( int work ) { } public void clearBlocked ( ) { } public void setBlocked ( IStatus reason ) { } } ProgressManager ( ) { } private void createChangeListener ( ) { } private void setUpImage ( URL iconsRoot , String fileName , String key ) throws MalformedURLException { } public IProgressMonitor createMonitor ( Job job ) { } public IProgressMonitor getDefaultMonitor ( ) { } public ProgressManager . JobMonitor progressFor ( Job job ) { } void addListener ( IJobProgressManagerListener listener ) { } void removeListener ( IJobProgressManagerListener listener ) { } JobInfo getJobInfo ( Job job ) { } public void refreshJobInfo ( JobInfo info ) { } public void refreshGroup ( GroupInfo info ) { } public void refreshAll ( ) { } public void removeJobInfo ( JobInfo info ) { } public void removeGroup ( GroupInfo group ) { } public void addJobInfo ( JobInfo info ) { } public void addGroup ( GroupInfo info ) { } boolean isNonDisplayableJob ( Job job , boolean debug ) { } private boolean isNeverDisplayedJob ( Job job ) { } public JobInfo [ ] getJobInfos ( boolean debug ) { } public JobTreeElement [ ] getRootElements ( boolean debug ) { } public boolean hasJobInfos ( ) { } private boolean hasNoRegularJobInfos ( ) { } Image getImage ( ImageData source ) { } ImageData [ ] getImageData ( URL fileSystemPath , ImageLoader loader ) { } public void busyCursorWhile ( final IRunnableWithProgress runnable ) throws InterruptedException , InvocationTargetException { <START_BUG> final ProgressMonitorJobsDialog dialog = new ProgressMonitorJobsDialog ( ProgressManagerUtil . getNonModalShell ( ) ) ; <END_BUG> dialog . setOpenOnRun ( false ) ; final InvocationTargetException [ ] invokes = new InvocationTargetException [ 1 ] ; final InterruptedException [ ] interrupt = new InterruptedException [ 1 ] ; Runnable dialogWaitRunnable = new Runnable ( ) { public void run ( ) { try { dialog . setOpenOnRun ( false ) ; setUserInterfaceActive ( false ) ; dialog . run ( true , true , runnable ) ; } catch ( InvocationTargetException e ) { invokes [ 0 ] = e ; } catch ( InterruptedException e ) { interrupt [ 0 ] = e ; } finally { setUserInterfaceActive ( true ) ; } } } ; busyCursorWhile ( dialogWaitRunnable , dialog ) ; if ( ( invokes [ 0 ] ) != null ) { throw invokes [ 0 ] ; } if ( ( interrupt [ 0 ] ) != null ) { throw interrupt [ 0 ] ; } } private void busyCursorWhile ( Runnable dialogWaitRunnable , ProgressMonitorJobsDialog dialog ) { } private void scheduleProgressMonitorJob ( final ProgressMonitorJobsDialog dialog ) { } private void shutdown ( ) { } public IProgressMonitor createProgressGroup ( ) { } public IProgressMonitor createMonitor ( Job job , IProgressMonitor group , int ticks ) { } void addListenerToFamily ( Object family , IJobBusyListener listener ) { } void removeListener ( IJobBusyListener listener ) { } private Collection busyListenersForJob ( Job job ) { } public void showInDialog ( Shell shell , Job job ) { } public void run ( boolean fork , boolean cancelable , IRunnableWithProgress runnable ) throws InterruptedException , InvocationTargetException { } public void runInUI ( final IRunnableContext context , final IRunnableWithProgress runnable , final ISchedulingRule rule ) throws InterruptedException , InvocationTargetException { } public int getLongOperationTime ( ) { } public void registerIconForFamily ( ImageDescriptor icon , Object family ) { } public Image getIconFor ( Job job ) { } private void setUserInterfaceActive ( boolean active ) { } private boolean pruneStaleJobs ( ) { } boolean checkForStaleness ( Job job ) { } private boolean shouldRunInBackground ( ) { } public void setShowSystemJobs ( boolean showSystem ) { } }

Fix:
final ProgressMonitorJobsDialog dialog = new ProgressMonitorJobsDialog ( ProgressManagerUtil . getDefaultParent ( ) ) ;