Merge pull request #22 from Oberon00/patch-1

Guard diagnostic_information against null what()
This commit is contained in:
Emil Dotchevski
2019-03-16 22:39:26 -07:00
committed by GitHub

View File

@ -161,7 +161,7 @@ boost
core::demangle((be?(BOOST_EXCEPTION_DYNAMIC_TYPEID(*be)):(BOOST_EXCEPTION_DYNAMIC_TYPEID(*se))).type_->name()) << '\n';
#endif
if( with_what && se && verbose )
tmp << "std::exception::what: " << wh << '\n';
tmp << "std::exception::what: " << (wh ? wh : "(null)") << '\n';
if( be )
if( char const * s=exception_detail::get_diagnostic_information(*be,tmp.str().c_str()) )
if( *s )