Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: src/WebRequestJsObject.cpp

Issue 6112412478472192: Issue 1547 - Pass isolate to v8::API (Closed)
Patch Set: Created Nov. 10, 2014, 9:05 a.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« src/GlobalJsObject.cpp ('K') | « src/Utils.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/WebRequestJsObject.cpp
===================================================================
--- a/src/WebRequestJsObject.cpp
+++ b/src/WebRequestJsObject.cpp
@@ -21,6 +21,7 @@
#include "JsContext.h"
#include "Thread.h"
+#include "Utils.h"
#include "WebRequestJsObject.h"
namespace
@@ -90,6 +91,8 @@
v8::Handle<v8::Value> GETCallback(const v8::Arguments& arguments)
{
WebRequestThread* thread;
+
+ v8::Isolate* isolate = arguments.GetIsolate();
Felix Dahlke 2015/02/05 04:58:24 Unnecessarily large scope again.
try
{
AdblockPlus::JsEnginePtr jsEngine = AdblockPlus::JsEngine::FromArguments(arguments);
@@ -100,7 +103,8 @@
}
catch (const std::exception& e)
{
- return v8::ThrowException(v8::String::New(e.what()));
+ using AdblockPlus::Utils::ToV8String;
+ return v8::ThrowException(ToV8String(isolate, e.what()));
}
thread->Start();
return v8::Undefined();
« src/GlobalJsObject.cpp ('K') | « src/Utils.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld