Always check VInitVolumePackage2 return code
authorAndrew Deason <adeason@sinenomine.net>
Mon, 11 Jan 2010 19:36:32 +0000 (13:36 -0600)
committerDerrick Brashear <shadow|account-1000005@unknown>
Thu, 14 Jan 2010 15:07:06 +0000 (07:07 -0800)
commit1544243167b0f294f080866710b3f29dec133f02
tree60f746e51a2b2cb00a3193ec0c71fa32101d233a
parent9b23804a82ea12b5d46e6ee2667ec05bed502081
Always check VInitVolumePackage2 return code

Some programs were not checking the return code of VInitVolumePackage2.
Although some programs do not care so much if we fail to properly init
the volume package (SYNC debug tools), at the very least log/print an
error, so it doesn't silently fail.

Other programs are changed to exit when VInitVolumePackage2 fail, so
e.g. salvages don't accidentally cause corruption on 'logging'-mounted
UFS partitions.

In any case, ensure the return code is always checked anywhere it is
called.

Change-Id: I164d5920a5ea2dd7e5ed9ad4ccc578e9bdf0db0b
Reviewed-on: http://gerrit.openafs.org/1090
Tested-by: Andrew Deason <adeason@sinenomine.net>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
src/tsalvaged/salvsync-debug.c
src/vol/fssync-debug.c
src/vol/salvaged.c
src/vol/salvager.c
src/vol/test/testpart.c
src/volser/vol-dump.c
src/volser/volmain.c