public void waitForListener(Process p)
			throws StopWaitingException, StartedGhidraProcessExitedException {
		if (!isGhidraListening()) {
			// set up periodic check for listener
			CheckForListenerRunnable checkForListener = new CheckForListenerRunnable(p, 100,
				TimeUnit.MILLISECONDS,
				() -> !isGhidraListening());

			// start checking for listener
			checkForListener.startChecking(100, TimeUnit.MILLISECONDS);

			// block until listener has been processed or user answers dialog with No.
			checkForListener.awaitTermination();
		}
	}
wait for a Ghidra to be listening and ready.
@param p ghidraRun process that is being waited for in the event that GhidraGo
started Ghidra
@throws StopWaitingException in the event waiting for a listener was stopped
@throws StartedGhidraProcessExitedException in the event a Ghidra was started and exited
unexpectedly.
Ghidra/Features/GhidraGo/src/main/java/ghidra/app/plugin/core/go/GhidraGoSender.java