[Lldb-commits] [lldb] r140417 - /lldb/trunk/source/Commands/CommandObjectTarget.cpp
Jason Molenda
jmolenda at apple.com
Fri Sep 23 14:15:42 PDT 2011
Author: jmolenda
Date: Fri Sep 23 16:15:42 2011
New Revision: 140417
URL: http://llvm.org/viewvc/llvm-project?rev=140417&view=rev
Log:
in CommandObjectTargetStopHookList::Execute, if we don't have a target,
return before we try to dereference the target later in the function.
Currently,
% lldb -x
(lldb) target stop-hook list
crashes because of this.
Modified:
lldb/trunk/source/Commands/CommandObjectTarget.cpp
Modified: lldb/trunk/source/Commands/CommandObjectTarget.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Commands/CommandObjectTarget.cpp?rev=140417&r1=140416&r2=140417&view=diff
==============================================================================
--- lldb/trunk/source/Commands/CommandObjectTarget.cpp (original)
+++ lldb/trunk/source/Commands/CommandObjectTarget.cpp Fri Sep 23 16:15:42 2011
@@ -3914,6 +3914,7 @@
{
result.AppendError ("invalid target\n");
result.SetStatus (eReturnStatusFailed);
+ return result.Succeeded();
}
size_t num_hooks = target->GetNumStopHooks ();
More information about the lldb-commits
mailing list