@@ -113,6 +113,7 @@ typedef struct verifier_context
113
113
manifest_data * manifest ;
114
114
char * backup_directory ;
115
115
SimpleStringList ignore_list ;
116
+ bool skip_checksums ;
116
117
bool exit_on_error ;
117
118
bool saw_any_error ;
118
119
} verifier_context ;
@@ -162,9 +163,8 @@ static void usage(void);
162
163
163
164
static const char * progname ;
164
165
165
- /* options */
166
+ /* is progress reporting enabled? */
166
167
static bool show_progress = false;
167
- static bool skip_checksums = false;
168
168
169
169
/* Progress indicators */
170
170
static uint64 total_size = 0 ;
@@ -266,7 +266,7 @@ main(int argc, char **argv)
266
266
quiet = true;
267
267
break ;
268
268
case 's' :
269
- skip_checksums = true;
269
+ context . skip_checksums = true;
270
270
break ;
271
271
case 'w' :
272
272
wal_directory = pstrdup (optarg );
@@ -363,7 +363,7 @@ main(int argc, char **argv)
363
363
* Now do the expensive work of verifying file checksums, unless we were
364
364
* told to skip it.
365
365
*/
366
- if (!skip_checksums )
366
+ if (!context . skip_checksums )
367
367
verify_backup_checksums (& context );
368
368
369
369
/*
@@ -739,7 +739,8 @@ verify_backup_file(verifier_context *context, char *relpath, char *fullpath)
739
739
verify_control_file (fullpath , context -> manifest -> system_identifier );
740
740
741
741
/* Update statistics for progress report, if necessary */
742
- if (show_progress && !skip_checksums && should_verify_checksum (m ))
742
+ if (show_progress && !context -> skip_checksums &&
743
+ should_verify_checksum (m ))
743
744
total_size += m -> size ;
744
745
745
746
/*
0 commit comments