From 10d31ea0a30ec47d68c79813d56e7506b1542f7e Mon Sep 17 00:00:00 2001 From: Andrew Grieve Date: Wed, 26 Jun 2013 14:20:45 -0400 Subject: [PATCH] Explicitly print exceptions that occur within ExposedJsApi. Before they trickled into JNI and the stack traces were lost. --- framework/src/org/apache/cordova/ExposedJsApi.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/framework/src/org/apache/cordova/ExposedJsApi.java b/framework/src/org/apache/cordova/ExposedJsApi.java index 40ab1e31..221dd3d5 100755 --- a/framework/src/org/apache/cordova/ExposedJsApi.java +++ b/framework/src/org/apache/cordova/ExposedJsApi.java @@ -54,6 +54,9 @@ import org.json.JSONException; ret = jsMessageQueue.popAndEncode(); } return ret; + } catch (Throwable e) { + e.printStackTrace(); + return ""; } finally { jsMessageQueue.setPaused(false); }