if (!isActive()) {
return;
}
inactive();
final JARequest oldCurrent = mailbox.getCurrentRequest();
final ExceptionHandler oldExceptionHandler = mailbox
.getExceptionHandler();
restoreSourceMailbox();
if (response instanceof Throwable) {
mailbox.setCurrentRequest(oldCurrent);
mailbox.setExceptionHandler(oldExceptionHandler);
if (response instanceof Exception) {
throw (Exception) response;
}
throw (Error) response;
}
try {
rp.processResponse(response);
} catch (final Throwable e) {
throw new TransparentException(e);
}
mailbox.setCurrentRequest(oldCurrent);
mailbox.setExceptionHandler(oldExceptionHandler);
} else {
if (response instanceof Throwable) {
Throwable ex = (Throwable) response;
final ExceptionHandler exceptionHandler = mailbox
.getExceptionHandler();
if (exceptionHandler != null) {
try {
exceptionHandler.process(ex);
return;
} catch (final Throwable x) {
ex = x;
}
mailbox.response(this, ex);