Bug 296822 NullProgressMonitor is not thread safe for expected usage
NullProgressMonitor.setCanceled and isCanceled access the cancelled field, but there's no synchronization. The expected use is that setCanceled is called from a thread other than the one doing the work, which polls isCanceled(), so this needs to be thread safe. Could either make these two methods synchronized or make the field volatile. Should check other progress monitor implementations too.
bundles/org.eclipse.jface/src/org/eclipse/jface/dialogs/ProgressMonitorDialog.java
/**
	 * Sets whether the dialog should be opened before the operation is run.
	 * NOTE: Setting this to false and not forking a process may starve any
	 * asyncExec that tries to open the dialog later.
	 * 
	 * @param openOnRun
	 *            <code>true</code> to open the dialog before run,
	 *            <code>false</code> to only create the dialog, but not open
	 *            it
	 * @since 3.0
	 */
	public void setOpenOnRun(boolean openOnRun) {
		this.openOnRun = openOnRun;
	}
	/**
	 * Returns the nesting depth of running operations.
	 * 
	 * @return the nesting depth of running operations
	 * @since 3.0
	 */
	protected int getNestingDepth() {
		return nestingDepth;
	}
	/**
	 * Increments the nesting depth of running operations.
	 * 
	 * @since 3.0
	 */
	protected void incrementNestingDepth() {
		nestingDepth++;