now works with -fno-exceptions and -fno-rtti
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@110828 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -54,15 +54,21 @@ std::set_terminate(std::terminate_handler func) throw()
|
||||
void
|
||||
std::terminate()
|
||||
{
|
||||
try {
|
||||
#ifndef _LIBCPP_NO_EXCEPTIONS
|
||||
try
|
||||
{
|
||||
#endif
|
||||
(*__terminate_handler)();
|
||||
// handler should not return
|
||||
::abort ();
|
||||
#ifndef _LIBCPP_NO_EXCEPTIONS
|
||||
}
|
||||
catch (...) {
|
||||
catch (...)
|
||||
{
|
||||
// handler should not throw exception
|
||||
::abort ();
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user