This initial version of sequence #233 would only print the output from the last command, because it reused the same SBCommandReturnObject for each command, which doesn't work due lldb calling Clear() within HandleCommand.
With this change, a fresh SBCommandReturnObject is used for each given command. If this temporary return object has output, it is appended to the main result object (self.result). If the command doesn't succeed, the error and status of the failed result are copied to the main self.result.
This initial version of
sequence
#233 would only print the output from the last command, because it reused the sameSBCommandReturnObject
for each command, which doesn't work due lldb callingClear()
withinHandleCommand
.With this change, a fresh
SBCommandReturnObject
is used for each given command. If this temporary return object has output, it is appended to the main result object (self.result
). If the command doesn't succeed, the error and status of the failed result are copied to the mainself.result
.