The current code, when it creates a sub process, does not set the parent field (proc.parent == null). The existing StopEventLoopOnProcDestroy is relying on that behavour. It needs to be replaced by something that instead matches a specific PID exiting.
2005-10-05 Andrew Cagney <cagney@redhat.com> * TestLib.java: For StopEventLoopOnProcDestroy, check that the proc is a child of frysk using getSelf. * TestExiting.java, TestTerminated.java: Ditto for ProcCreatedObserver. * TestLib.java: For ProcCounter, replace numberAdded and numberRemoved with getAdjustNumberAdded and getAdustedNumberRemoved. Add getAdjustedHostProcPoolSize. * TestRun.java, TestFork.java: Update