mirror of
https://github.com/boostorg/core.git
synced 2025-07-30 04:47:24 +02:00
Only return an 8 bit result from report_errors
This commit is contained in:
@ -379,6 +379,7 @@ inline int report_errors()
|
|||||||
result.done();
|
result.done();
|
||||||
|
|
||||||
int errors = result.errors();
|
int errors = result.errors();
|
||||||
|
|
||||||
if( errors == 0 )
|
if( errors == 0 )
|
||||||
{
|
{
|
||||||
BOOST_LIGHTWEIGHT_TEST_OSTREAM
|
BOOST_LIGHTWEIGHT_TEST_OSTREAM
|
||||||
@ -389,7 +390,9 @@ inline int report_errors()
|
|||||||
BOOST_LIGHTWEIGHT_TEST_OSTREAM
|
BOOST_LIGHTWEIGHT_TEST_OSTREAM
|
||||||
<< errors << " error" << (errors == 1? "": "s") << " detected." << std::endl;
|
<< errors << " error" << (errors == 1? "": "s") << " detected." << std::endl;
|
||||||
}
|
}
|
||||||
return errors;
|
|
||||||
|
// `return report_errors();` from main only supports 8 bit exit codes
|
||||||
|
return errors < 256? errors: 255;
|
||||||
}
|
}
|
||||||
|
|
||||||
} // namespace boost
|
} // namespace boost
|
||||||
|
Reference in New Issue
Block a user