summaryrefslogtreecommitdiff
path: root/source/Symbol/Variable.cpp
diff options
context:
space:
mode:
authorEd Maste <emaste@FreeBSD.org>2013-11-06 16:48:53 +0000
committerEd Maste <emaste@FreeBSD.org>2013-11-06 16:48:53 +0000
commitf21a844f60ae6c74fcf1fddca32461acce3c1ee0 (patch)
tree56d79f94966870db1cecd65a7264510a25fd1cba /source/Symbol/Variable.cpp
parent37d22554be9f5a677dad2a95b7ef22fe59c66a8a (diff)
Notes
Diffstat (limited to 'source/Symbol/Variable.cpp')
-rw-r--r--source/Symbol/Variable.cpp11
1 files changed, 7 insertions, 4 deletions
diff --git a/source/Symbol/Variable.cpp b/source/Symbol/Variable.cpp
index 36439b561626e..7276e0a4a1a2d 100644
--- a/source/Symbol/Variable.cpp
+++ b/source/Symbol/Variable.cpp
@@ -684,11 +684,14 @@ PrivateAutoComplete (StackFrame *frame,
VariableList *variable_list = frame->GetVariableList(get_file_globals);
- const size_t num_variables = variable_list->GetSize();
- for (size_t i=0; i<num_variables; ++i)
+ if (variable_list)
{
- Variable *variable = variable_list->GetVariableAtIndex(i).get();
- matches.AppendString (variable->GetName().AsCString());
+ const size_t num_variables = variable_list->GetSize();
+ for (size_t i=0; i<num_variables; ++i)
+ {
+ Variable *variable = variable_list->GetVariableAtIndex(i).get();
+ matches.AppendString (variable->GetName().AsCString());
+ }
}
}
}