Log.log(Platform.class, "WPAD detection failed due to:");
if (e instanceof EcmaError) Log.log(HTTP.class, ((EcmaError)e).getMessage() + " at " +
((EcmaError)e).getSourceName() + ":" + ((EcmaError)e).getLineNumber());
- else if (e instanceof JSObject)
- XWT.recursivePrintObject.call(Context.enter(), null, null, new Object[] { e });
+ else if (e instanceof JavaScriptException) {
+ try {
+ XWT.recursivePrintObject.call(Context.enter(), null, null, new Object[] {
+ ((JavaScriptException)e).getValue() });
+ } catch (Exception e2) {
+ Log.log(Platform.class, e);
+ }
+ }
else Log.log(Platform.class, e);
}
return null;
}
static final JSObject.JSFunction recursivePrintObject = new JSObject.JSFunction() {
- public Object call(Context cx, Scriptable thisObj, Scriptable ctorObj, Object[] args) throws JavaScriptException {
+ public Object call(Context cx, Scriptable thisObj, Scriptable ctorObj, Object[] args) {
if (args == null || args.length != 1) return null;
recurse("", "", args[0], cx);
return null;