Skip to content

Commit

Permalink
Update example/hash2sum.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
pdimov committed Nov 13, 2024
1 parent 8898f46 commit 27b2ed0
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions example/hash2sum.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,8 @@ using hashes = mp_list<
sha2_384,
sha2_512_256,
sha2_512_224,
ripemd_160
ripemd_160,
ripemd_128

>;

Expand All @@ -83,7 +84,8 @@ constexpr char const* names[] = {
"sha2_384",
"sha2_512_256",
"sha2_512_224",
"ripemd_160"
"ripemd_160",
"ripemd_128"

};

Expand Down Expand Up @@ -116,7 +118,13 @@ int main( int argc, char const* argv[] )

if( !found )
{
std::fprintf( stderr, "hash2sum: unknown hash name '%s'\n", hash.c_str() );
std::fprintf( stderr, "hash2sum: unknown hash algorithm name '%s'; use one of the following:\n\n", hash.c_str() );

for( char const* name: names )
{
std::fprintf( stderr, " %s\n", name );
}

return 1;
}
}

0 comments on commit 27b2ed0

Please sign in to comment.