Debugger: Fix crash in context menu builder.

A value node might not have a location due to e.g. issues resolving its parent.
Guard against this case and simply return early as we won't be able to take any
meaningful actions on such a node. Fixes the second crash listed in #10781.
This commit is contained in:
Rene Gollent 2014-04-25 21:51:47 -04:00
parent 667cfcdd56
commit e10e704441

View File

@ -2042,6 +2042,9 @@ VariablesView::_GetContextActionsForNode(ModelNode* node,
ContextActionList* actions)
{
ValueLocation* location = node->NodeChild()->Location();
if (location == NULL)
return B_OK;
status_t result = B_OK;
BMessage* message = NULL;