Browse Source

removed nested faulty handle scopes in libjsengine

cl-refactor
unknown 9 years ago
parent
commit
08756f6c06
  1. 1
      libjsengine/JSV8Engine.cpp
  2. 1
      libjsengine/JSV8Printer.cpp

1
libjsengine/JSV8Engine.cpp

@ -161,7 +161,6 @@ JSV8Engine::~JSV8Engine()
JSV8Value JSV8Engine::eval(char const* _cstr) const
{
v8::HandleScope handleScope;
v8::TryCatch tryCatch;
v8::Local<v8::String> source = v8::String::New(_cstr);
v8::Local<v8::String> name(v8::String::New("(shell)"));

1
libjsengine/JSV8Printer.cpp

@ -37,7 +37,6 @@ JSV8Printer::JSV8Printer(JSV8Engine const& _engine): m_engine(_engine)
JSString JSV8Printer::prettyPrint(JSV8Value const& _value) const
{
v8::HandleScope handleScope;
v8::Local<v8::String> pp = v8::String::New("prettyPrint");
v8::Handle<v8::Function> func = v8::Handle<v8::Function>::Cast(m_engine.context()->Global()->Get(pp));
v8::Local<v8::Value> values[1] = {v8::Local<v8::Value>::New(_value.value())};

Loading…
Cancel
Save