Make "process attach -c" work correctly, and add a test for it.
authorJim Ingham <jingham@apple.com>
Thu, 30 Sep 2021 02:38:09 +0000 (19:38 -0700)
committerJim Ingham <jingham@apple.com>
Thu, 30 Sep 2021 02:38:09 +0000 (19:38 -0700)
commit2303391d1f543f4e57f9ed0fc68bad2d4cf890dc
tree9bf5a8e31f90c14601678f678bcc1778860df30a
parent3bf3b96629e8dfc55d01ba0cb05ca01a467017fa
Make "process attach -c" work correctly, and add a test for it.

The issue here was that we were not updating the interpreter's
execution context when calling HandleCommand to continue the process.
Since we had just created the process, it wasn't in the interpreter's
execution context so HandleCommand failed at CheckRequirements.  The
patch fixes that by passing the process execution context directly
to HandleCommand.

Differential Revision: https://reviews.llvm.org/D110787
lldb/source/Commands/CommandObjectProcess.cpp
lldb/test/API/commands/process/attach/TestProcessAttach.py