* Modified bin/BackupPC_dump to fix the case of a single partial
[BackupPC.git] / bin / BackupPC_dump
index 3e212d0..288ee85 100755 (executable)
@@ -70,7 +70,7 @@
 #
 #========================================================================
 #
-# Version 3.1.0, released 25 Nov 2007.
+# Version 3.2.0, released 31 Dec 2008.
 #
 # See http://backuppc.sourceforge.net.
 #
@@ -234,7 +234,7 @@ if ($Conf{XferMethod} eq "archive" ) {
     exit(0);
 }
 
-if ( !$opts{d} ) {
+if ( !$opts{d} && !$Conf{BackupsDisable} ) {
     #
     # In the non-DHCP case, make sure the host can be looked up
     # via NS, or otherwise find the IP address via NetBios.
@@ -413,7 +413,7 @@ for ( my $i = 0 ; $i < @Backups ; $i++ ) {
 #
 # Decide whether we do nothing, or a full or incremental backup.
 #
-if ( @Backups == 0
+if ( $lastFullTime == 0
         || $opts{f}
         || (!$opts{i} && (time - $lastFullTime > $Conf{FullPeriod} * 24*3600
             && time - $lastIncrTime > $Conf{IncrPeriod} * 24*3600)) ) {
@@ -1628,6 +1628,7 @@ sub UserCommandRun
     $bpc->cmdSystemOrEval($cmd,
            sub {
                $XferLOG->write(\$_[0]);
+                print(LOG $bpc->timeStamp, "Output from $cmdType: ", $_[0]);
            },
            $vars, \%Conf);
 }