@SuppressWarnings("deprecation")
    private static void waitForMethodThreads(
	    LinkedList<java.lang.Thread> threads, final Throwable[] error)
	    throws Throwable {
	for (java.lang.Thread t : threads)
	    try {
		if (t.isAlive() && error[0] != null)
		    t.stop();
		else
		    t.join();
	    } catch (InterruptedException e1) {
		if (error[0] != null)
		    throw error[0];
		throw new AssertionError(e1);
	    }
	if (error[0] != null)
	    throw error[0];
    }