Merging upstream version 1.25~pre1.
Signed-off-by: Daniel Baumann <daniel@debian.org>
This commit is contained in:
parent
8062cdcacd
commit
3e4c2fba01
60 changed files with 5261 additions and 1250 deletions
28
lunzcrash.cc
28
lunzcrash.cc
|
@ -205,15 +205,16 @@ int lunzcrash_bit( const char * const input_filename,
|
|||
|
||||
if( verbosity >= 0 )
|
||||
{
|
||||
std::printf( "\n%9ld bytes tested\n%9ld total decompressions"
|
||||
"\n%9ld decompressions returned with zero status",
|
||||
positions, decompressions, successes );
|
||||
std::printf( "\n%11s bytes tested\n%11s total decompressions"
|
||||
"\n%11s decompressions returned with zero status",
|
||||
format_num3( positions ), format_num3( decompressions ),
|
||||
format_num3( successes ) );
|
||||
if( successes > 0 )
|
||||
{
|
||||
if( failed_comparisons > 0 )
|
||||
std::printf( ", of which\n%9ld comparisons failed\n",
|
||||
failed_comparisons );
|
||||
else std::fputs( "\n all comparisons passed\n", stdout );
|
||||
std::printf( ", of which\n%11s comparisons failed\n",
|
||||
format_num3( failed_comparisons ) );
|
||||
else std::fputs( "\n all comparisons passed\n", stdout );
|
||||
}
|
||||
else std::fputc( '\n', stdout );
|
||||
}
|
||||
|
@ -319,15 +320,16 @@ int lunzcrash_block( const char * const input_filename,
|
|||
|
||||
if( verbosity >= 0 )
|
||||
{
|
||||
std::printf( "\n%9ld blocks tested\n%9ld total decompressions"
|
||||
"\n%9ld decompressions returned with zero status",
|
||||
decompressions, decompressions, successes );
|
||||
std::printf( "\n%11s blocks tested\n%11s total decompressions"
|
||||
"\n%11s decompressions returned with zero status",
|
||||
format_num3( decompressions ), format_num3( decompressions ),
|
||||
format_num3( successes ) );
|
||||
if( successes > 0 )
|
||||
{
|
||||
if( failed_comparisons > 0 )
|
||||
std::printf( ", of which\n%9ld comparisons failed\n",
|
||||
failed_comparisons );
|
||||
else std::fputs( "\n all comparisons passed\n", stdout );
|
||||
std::printf( ", of which\n%11s comparisons failed\n",
|
||||
format_num3( failed_comparisons ) );
|
||||
else std::fputs( "\n all comparisons passed\n", stdout );
|
||||
}
|
||||
else std::fputc( '\n', stdout );
|
||||
}
|
||||
|
@ -357,7 +359,7 @@ int md5sum_files( const std::vector< std::string > & filenames )
|
|||
while( true )
|
||||
{
|
||||
const int len = readblock( infd, buffer, buffer_size );
|
||||
if( len != buffer_size && errno ) throw Error( "Read error" );
|
||||
if( len != buffer_size && errno ) throw Error( read_error_msg );
|
||||
if( len > 0 ) md5sum.md5_update( buffer, len );
|
||||
if( len < buffer_size ) break;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue