BackupPC-users

[BackupPC-users] REGRESSION WITH FIX: parity command runs when parity is set to 0

2012-04-03 15:27:07
Subject: [BackupPC-users] REGRESSION WITH FIX: parity command runs when parity is set to 0
From: Timothy J Massey <tmassey AT obscorp DOT com>
To: "General list for user discussion, questions and support" <backuppc-users AT lists.sourceforge DOT net>
Date: Tue, 3 Apr 2012 15:13:17 -0400
Hello!

In BackupPC 3.1.0, if I were to set the parity of an archive ($parfile) to 0, the parity would not run.  That meets what the documentation says.  However, in 3.2.0, the parity still runs, even when set to 0.

Here is the relevant code for 3.1.0 (BackupPC_archiveHost line 148):

if ( $parfile != 0 ) {

Here is the relevant code for 3.2.0 (line 157):

    if ( length($parfile) ) {

Obviously, these two are not the same.  The length of my $parfile when set to "0" is *not* zero!  I'm not sure why the line was changed between 3.1.0 and 3.2.0.  I don't want to break someone else's system.  So should maybe these two be combined?  Something like:

-    if ( length($parfile) ) {
+    if ( length($parfile) && $parfile != 0 ) {


Tim Massey
 
Out of the Box Solutions, Inc.
Creative IT Solutions Made Simple!

http://www.OutOfTheBoxSolutions.com
tmassey AT obscorp DOT com
      22108 Harper Ave.
St. Clair Shores, MI 48080
Office: (800)750-4OBS (4627)
Cell: (586)945-8796

------------------------------------------------------------------------------
Better than sec? Nothing is better than sec when it comes to
monitoring Big Data applications. Try Boundary one-second 
resolution app monitoring today. Free.
http://p.sf.net/sfu/Boundary-dev2dev
_______________________________________________
BackupPC-users mailing list
BackupPC-users AT lists.sourceforge DOT net
List:    https://lists.sourceforge.net/lists/listinfo/backuppc-users
Wiki:    http://backuppc.wiki.sourceforge.net
Project: http://backuppc.sourceforge.net/
<Prev in Thread] Current Thread [Next in Thread>
  • [BackupPC-users] REGRESSION WITH FIX: parity command runs when parity is set to 0, Timothy J Massey <=