HomePhabricator

[lldb] Don't use ::exit but instead return from the driver loop (NFC)

Authored by JDevlieghere on Nov 9 2020, 4:36 PM.

Description

[lldb] Don't use ::exit but instead return from the driver loop (NFC)

This fixes a reproducer test failure that was caused by the undefined
order in which global destructors run. More concretely, the static
instance of the RealFileSystem had been destroyed before we finalized
the reproducer, which uses it to copy files into the reproducer. By
exiting normally, we call SBDebugger::Terminate and finalize the
reproducer before any static dtors are run.

Details

Committed
JDevlieghereNov 9 2020, 4:47 PM
Parents
rG6ac12b5b6c5d: [lldb] Destory the debugger in the Driver dtor (NFC)
Branches
Unknown
Tags
Unknown