Index: runtime/vm/service.cc |
diff --git a/runtime/vm/service.cc b/runtime/vm/service.cc |
index 0593f7faa5edd29610cd8a5c1f164c3c2c2aecf0..6fb3470f4e734fbf37f1b96f0e17e4f359e7a98b 100644 |
--- a/runtime/vm/service.cc |
+++ b/runtime/vm/service.cc |
@@ -780,6 +780,7 @@ static const MethodParameter* get_stack_params[] = { |
static bool GetStack(Isolate* isolate, JSONStream* js) { |
+ ASSERT(isolate->debugger() != NULL); |
DebuggerStackTrace* stack = isolate->debugger()->StackTrace(); |
// Do we want the complete script object and complete local variable objects? |
// This is true for dump requests. |
@@ -1255,6 +1256,7 @@ static void PrintSentinel(JSONStream* js, SentinelType sentinel_type) { |
static Breakpoint* LookupBreakpoint(Isolate* isolate, const char* id) { |
+ ASSERT(isolate->debugger() != NULL); |
size_t end_pos = strcspn(id, "/"); |
if (end_pos == strlen(id)) { |
return NULL; |
@@ -1621,6 +1623,7 @@ static const MethodParameter* evaluate_in_frame_params[] = { |
static bool EvaluateInFrame(Isolate* isolate, JSONStream* js) { |
+ ASSERT(isolate->debugger() != NULL); |
DebuggerStackTrace* stack = isolate->debugger()->StackTrace(); |
intptr_t framePos = UIntParameter::Parse(js->LookupParam("frameIndex")); |
if (framePos > stack->Length()) { |
@@ -1856,6 +1859,7 @@ static const MethodParameter* add_breakpoint_params[] = { |
static bool AddBreakpoint(Isolate* isolate, JSONStream* js) { |
+ ASSERT(isolate->debugger() != NULL); |
const char* line_param = js->LookupParam("line"); |
intptr_t line = UIntParameter::Parse(line_param); |
const char* script_id = js->LookupParam("scriptId"); |
@@ -1887,6 +1891,7 @@ static const MethodParameter* add_breakpoint_at_entry_params[] = { |
static bool AddBreakpointAtEntry(Isolate* isolate, JSONStream* js) { |
+ ASSERT(isolate->debugger() != NULL); |
const char* function_id = js->LookupParam("functionId"); |
Object& obj = Object::Handle(LookupHeapObject(isolate, function_id, NULL)); |
if (obj.raw() == Object::sentinel().raw() || !obj.IsFunction()) { |
@@ -1915,6 +1920,7 @@ static const MethodParameter* add_breakpoint_at_activation_params[] = { |
static bool AddBreakpointAtActivation(Isolate* isolate, JSONStream* js) { |
+ ASSERT(isolate->debugger() != NULL); |
const char* object_id = js->LookupParam("objectId"); |
Object& obj = Object::Handle(LookupHeapObject(isolate, object_id, NULL)); |
if (obj.raw() == Object::sentinel().raw() || !obj.IsInstance()) { |
@@ -1942,6 +1948,7 @@ static const MethodParameter* remove_breakpoint_params[] = { |
static bool RemoveBreakpoint(Isolate* isolate, JSONStream* js) { |
+ ASSERT(isolate->debugger() != NULL); |
if (!js->HasParam("breakpointId")) { |
PrintMissingParamError(js, "breakpointId"); |
return true; |
@@ -2147,6 +2154,7 @@ static const MethodParameter* resume_params[] = { |
static bool Resume(Isolate* isolate, JSONStream* js) { |
+ ASSERT(isolate->debugger() != NULL); |
const char* step_param = js->LookupParam("step"); |
if (isolate->message_handler()->paused_on_start()) { |
isolate->message_handler()->set_pause_on_start(false); |