Fix handling of test failures due to uncaught exceptions

We don't just want to exit here, but `longjmp()` back to the conditional
via a call to `DeepState_Fail()`. In doing so, we end up in the common
`DeepState_CatchFail()` branch, which exits with the same nonzero error
code, but also saves the test case if appropriate.
This commit is contained in:
Joe Ranweiler
2018-02-14 10:10:51 -08:00
parent a68520642a
commit 68595a9493

View File

@@ -423,7 +423,7 @@ static void DeepState_RunTest(struct DeepState_TestInfo *test) {
#if defined(__cplusplus) && defined(__cpp_exceptions)
} catch(...) {
exit(1);
DeepState_Fail();
}
#endif /* __cplusplus */