Comment #1 on issue 2414 by [email protected]: Cannot TerminateExecution() on an active debugged script
http://code.google.com/p/v8/issues/detail?id=2414

Note 2:

from api.cc:2319 (version 3.14.5), from Value::ToString()

    i::Isolate* isolate = i::Isolate::Current();
    if (IsDeadCheck(isolate, "v8::Value::ToString()")) {
      return Local<String>();
    }
    LOG_API(isolate, "ToString");
    ENTER_V8(isolate);
    EXCEPTION_PREAMBLE(isolate);

This code checks IsDeadCheck(), but it does not check IsExecutionTerminatingCheck(),

perhaps the if(IsDeadCheck()) should be replaced with ON_BAILOUT() ?

I tried this, but my manual debugger test failed in a different way, because the code here: debug.cc:3118

    } else {
      // In case of failure the result text is the exception text.
      response = try_catch.Exception()->ToString();
    }

    // Return the result.
    MessageImpl message = MessageImpl::NewResponse(
        event,
        running,
        Handle<JSObject>::cast(exec_state),
        Handle<JSObject>::cast(event_data),
        Handle<String>(Utils::OpenHandle(*response)),
        command.client_data());


Note that try_catch.Exception()->ToString() no longer crashes, but instead returns an empty handle. But now Utils::OpenHandle(*response) crashes as it tries to dereference a null pointer.



--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev

Reply via email to