Merge pull request #400 from PartialVolume/Fix_summary_table_on_specific_failure

Fix obscure incorrect summary table status
This commit is contained in:
PartialVolume
2022-01-12 21:14:22 +00:00
committed by GitHub
2 changed files with 14 additions and 3 deletions

View File

@@ -722,10 +722,21 @@ int main( int argc, char** argv )
{
for( i = 0; i < nwipe_selected; i++ )
{
/* Check for non-fatal errors. */
/* Check for errors. */
if( c2[i]->result != 0 || c2[i]->pass_errors != 0 || c2[i]->verify_errors != 0
|| c2[i]->fsyncdata_errors != 0 )
{
/* If the run_method ever returns anything other than zero then makesure there is at least one pass
* error This is so that the log summary tables correctly show a failure when one occurs as it only
* shows pass, verification and fdatasync errors. */
if( c2[i]->result != 0 )
{
if( c2[i]->pass_errors == 0 )
{
c2[i]->pass_errors = 1;
}
}
nwipe_log( NWIPE_LOG_FATAL,
"Nwipe exited with errors on device = %s, see log for specific error\n",
c2[i]->device_name );

View File

@@ -4,7 +4,7 @@
* used by configure to dynamically assign those values
* to documentation files.
*/
const char* version_string = "0.32.021";
const char* version_string = "0.32.022";
const char* program_name = "nwipe";
const char* author_name = "Martijn van Brummelen";
const char* email_address = "git@brumit.nl";
@@ -14,4 +14,4 @@ Modifications to original dwipe Copyright Andy Beverley <andy@andybev.com>\n\
This is free software; see the source for copying conditions.\n\
There is NO warranty; not even for MERCHANTABILITY or FITNESS\n\
FOR A PARTICULAR PURPOSE.\n";
const char* banner = "nwipe 0.32.021";
const char* banner = "nwipe 0.32.022";