[Piuparts-commits] [SCM] piuparts git repository branch, piatti, updated. 0.46-19-g5ed50ea

Andreas Beckmann debian at abeckmann.de
Sat Sep 15 14:30:04 UTC 2012


The following commit has been merged in the piatti branch:
commit 72e8a74c1dc2fb90243c1d68d89f2fd81e1d99fc
Author: Andreas Beckmann <debian at abeckmann.de>
Date:   Sat Sep 15 12:34:20 2012 +0200

    reschedule_oldest_logs: fix duplicate use of COUNT variable
    
    do not overwrite a global default limit with a local count
    
    Signed-off-by: Andreas Beckmann <debian at abeckmann.de>

diff --git a/debian/changelog b/debian/changelog
index 1495195..7a3db99 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -14,6 +14,8 @@ piuparts (0.47) UNRELEASED; urgency=low
     pre_remove_50_find_bad_permissions to avoid early failures during upgrade
     tests that may be fixed in a later version.
   * Remove post_purge_dbconfig_cleanup custom script.
+  * reschedule_oldest_logs: Refactored.
+    - Fix duplicate variable name usage that soemetimes prevented recycling.
 
  -- Andreas Beckmann <debian at abeckmann.de>  Sat, 15 Sep 2012 06:25:05 +0200
 
diff --git a/master-bin/reschedule_oldest_logs b/master-bin/reschedule_oldest_logs
index 1a34097..621f33a 100755
--- a/master-bin/reschedule_oldest_logs
+++ b/master-bin/reschedule_oldest_logs
@@ -85,11 +85,11 @@ for SECTION in $SECTIONS ; do
 	fi
 
 	if [ -s $LOGS ] || [ -s $OBSOLETE ]; then
-		COUNT=$(wc -l $LOGS | awk '{ print $1 }')
-		TOTAL=$(($TOTAL + $COUNT))
+		RCOUNT=$(wc -l $LOGS | awk '{ print $1 }')
+		TOTAL=$(($TOTAL + $RCOUNT))
 		UCOUNT=$(wc -l $OBSOLETE | awk '{ print $1 }')
 		UNSCHEDULE=$(($UNSCHEDULE + $UCOUNT))
-		echo "$SECTION: $COUNT/$UCOUNT"
+		echo "$SECTION: $RCOUNT/$UCOUNT"
 		if [ -s $LOGS ]; then
 			ls -dtl $(cat $LOGS)
 			ln -f $(cat $LOGS) recycle/

-- 
piuparts git repository



More information about the Piuparts-commits mailing list