* Do not print out exception messages multiple times.

* Create a scripting exception wrapping the original exception.
This commit is contained in:
hns 2002-11-22 14:40:51 +00:00
parent c1338c3d67
commit 4babc5c850

View file

@ -419,15 +419,11 @@ public final class FesiEngine implements ScriptingEngine {
// has the request timed out? If so, throw TimeoutException
if (evaluator.thread != Thread.currentThread())
throw new TimeoutException ();
// create and throw a ScriptingException with the right message
String msg = x.getMessage ();
if (msg == null || msg.length() < 10)
msg = x.toString ();
if (app.debug ()) {
System.err.println ("Error in Script: "+msg);
x.printStackTrace ();
}
throw new ScriptingException (msg);
// create and throw a ScriptingException wrapping the original exception
throw new ScriptingException (x);
}
}