diff --git a/lldb/scripts/Python/python-wrapper.swig b/lldb/scripts/Python/python-wrapper.swig index 75b082ffe0c4..646323a21cdc 100644 --- a/lldb/scripts/Python/python-wrapper.swig +++ b/lldb/scripts/Python/python-wrapper.swig @@ -16,7 +16,7 @@ public: { if (PyErr_Occurred()) { - if(m_print) + if(m_print && !PyErr_ExceptionMatches(PyExc_SystemExit)) PyErr_Print(); PyErr_Clear(); }