err.println("Exception in command"); ex.printStackTrace(err); unblock();
err.println("Exception in command"); ex.printStackTrace(err); unblock(); } catch (Error ex) { err.println("Error in command"); ex.printStackTrace(err); unblock();
        public void run() {            try {                // System.err.println("Registering shell in new thread.");                // to                // ensure                // access                // to                // the                // command                // shell                // in                // this                // new                // thread?                try {                	Object obj = null;                	if(!Modifier.isStatic(method.getModifiers())) {                		obj = cx.newInstance();                	}                		AccessController.doPrivileged(new InvokeAction(method,                            obj, args));                } catch (PrivilegedActionException ex) {                    throw ex.getException();                }                if (!isBlocking()) {                    // somebody already hit ctrl-c.                } else {                    finished = true;                    // System.err.println("Finished invocation, notifying                    // blockers.");                    // done with invoke, stop waiting for a ctrl-c                    unblock();                }            } catch (InvocationTargetException ex) {                Throwable tex = ex.getTargetException();                if (tex instanceof SyntaxErrorException) {                    try {                        Help.getInfo(cx).usage();                    } catch (HelpException ex1) {                        // Don't care                        ex1.printStackTrace();                    }                    err.println(tex.getMessage());                    unblock();                } else if (tex instanceof VmExit) {                    err.println(tex.getMessage());                    unblock();                } else {                    err.println("Exception in command");                    tex.printStackTrace(err);                    unblock();                }            } catch (Exception ex) {                err.println("Exception in command");                ex.printStackTrace(err);                unblock();            }            finished = true;        }