Add tests for calling message with nullptr buffer

This commit is contained in:
Mohammad Nejati
2024-06-02 09:52:50 +00:00
parent be5a8ffa80
commit 8a92683012
2 changed files with 6 additions and 0 deletions

View File

@ -24,6 +24,9 @@ int main()
BOOST_TEST_EQ( ec.to_string(), std::string( "system:0" ) );
// when len is 0 buffer can be nullptr
ec.message( nullptr, 0 );
{
sys::error_code ec2( ec );

View File

@ -24,6 +24,9 @@ int main()
BOOST_TEST_EQ( en.to_string(), std::string( "cond:generic:0" ) );
// when len is 0 buffer can be nullptr
en.message( nullptr, 0 );
{
sys::error_condition en2( en );