private void waitForPreSave(TaskMonitor monitor) throws CancelledException {

		PreSaveTask task;
		synchronized (preSaveLock) {
			task = preSaveTask;
		}
		if (task != null) {
			task.waitForTask(monitor);
		}
	}
Block until pre-save thread completes
@param monitor optional monitor allowing the pre-save wait to be interrupted/canceled - the actual pre-save will 
continue since it may be required for a future save operation.
@throws CancelledException
Ghidra/Framework/DB/src/main/java/db/buffers/LocalManagedBufferFile.java