X-Git-Url: http://git.rot13.org/?p=BackupPC.git;a=blobdiff_plain;f=bin%2FBackupPC_archiveHost;h=4bad6c68d9a932bbdb2eaf20cbcaf7578853a5d4;hp=e2ee002ac7c53e8b022fb0473e9ede80196c0e8d;hb=e951f787a66c5bd9e9955c3f657a5b44289c0fe1;hpb=07d524e222fd3eeffccd2355f4a20ca5eba82f1b diff --git a/bin/BackupPC_archiveHost b/bin/BackupPC_archiveHost index e2ee002..4bad6c6 100755 --- a/bin/BackupPC_archiveHost +++ b/bin/BackupPC_archiveHost @@ -38,7 +38,7 @@ # #======================================================================== # -# Version 2.1.0beta2, released 23 May 2004. +# Version 2.1.0, released 20 Jun 2004. # # See http://backuppc.sourceforge.net. # @@ -102,7 +102,7 @@ if ( -b $outLoc || -c $outLoc || -f $outLoc ) { print("Error: unable to create output directory $outLoc\n"); exit(1); } - if ( $splitSize && -x $splitPath ) { + if ( $splitSize > 0 && -x $splitPath ) { $cmd .= "| $splitPath -b $splitSize - $outLoc/$host.$bkupNum.tar$fileExt."; $mesg .= ", split to output files $outLoc/$host.$bkupNum.tar$fileExt.*"; } else { @@ -117,6 +117,7 @@ print("$mesg\n"); # my $ret = system($cmd); if ( $ret ) { + print("Executing: $cmd\n"); print("Error: $tarCreate, compress or split failed\n"); exit(1); } @@ -128,8 +129,10 @@ if ( $ret ) { if ( -d $outLoc && -x $parPath ) { if ( $parfile != 0 ) { print("Running $parPath to create parity files\n"); - $ret = system("$parPath c -r$parfile $outLoc/$host.$bkupNum.tar$fileExt.par2 $outLoc/$host.$bkupNum.tar$fileExt.*"); + my $parCmd = "$parPath c -r$parfile $outLoc/$host.$bkupNum.tar$fileExt.par2 $outLoc/$host.$bkupNum.tar$fileExt.*"; + $ret = system($parCmd); if ( $ret ) { + print("Executing: $parCmd\n"); print("Error: $parPath failed\n"); exit(1); }