From a6fd4ba0b487476d1060d73d248f0d8edf53d40e Mon Sep 17 00:00:00 2001 From: "yangguo@chromium.org" Date: Mon, 7 Jul 2014 07:23:41 +0000 Subject: [PATCH] Wrap captureStackTrace in a try-catch when constructing an error. TBR=verwaest@chromium.org Review URL: https://codereview.chromium.org/370993003 git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@22225 ce2b1a6d-e550-0410-aec6-3dcde31c8c00 --- src/messages.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/messages.js b/src/messages.js index 1df1c8c..e3d941b 100644 --- a/src/messages.js +++ b/src/messages.js @@ -1189,7 +1189,7 @@ function SetUpError() { if (!IS_UNDEFINED(m)) { %AddProperty(this, 'message', ToString(m), DONT_ENUM); } - captureStackTrace(this, f); + try { captureStackTrace(this, f); } catch (e) { } } else { return new f(m); } -- 2.7.4