[Popcon-commits] cvs commit to popularity-contest by ballombe

popcon-commits@lists.alioth.debian.org popcon-commits@lists.alioth.debian.org
Tue, 07 Jun 2005 14:53:47 +0000


Update of /cvsroot/popcon/popularity-contest
In directory haydn:/tmp/cvs-serv12293

Modified Files:
	popularity-contest 
Log Message:
Remove extraneous space at end of lines.


Index: popularity-contest
===================================================================
RCS file: /cvsroot/popcon/popularity-contest/popularity-contest,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -d -r1.11 -r1.12
--- popularity-contest	8 Nov 2004 20:33:56 -0000	1.11
+++ popularity-contest	7 Jun 2005 14:53:45 -0000	1.12
@@ -77,7 +77,7 @@
 {
   /^.*installed *(.+)$/ or next;
   my $pkg=$1;
-  $popcon{$pkg}=[0,0,$pkg,"<NOFILES>",""];
+  $popcon{$pkg}=[0,0,$pkg,"<NOFILES>"];
   open FILES, "$dpkg_db/$pkg.list";
   my $bestatime = undef;
   while (<FILES>)
@@ -92,20 +92,22 @@
     if (!defined($bestatime) || $atime >= $bestatime)
     {
       $bestatime=$atime;
-      my $st="";
       if ($atime < $lastmonth)
       { 
         # Not accessed since more than 30 days.
-        $st="<OLD>";
+        $popcon{$pkg}=[$atime,$ctime,$pkg,$_,"<OLD>"];
       }
       elsif ($ctime > $lastmonth && $atime-$ctime < $daylen)
       {
         # Installed/upgraded less than a month ago and not used after 
         # install/upgrade day.
-        $st="<RECENT-CTIME>";
+        $popcon{$pkg}=[$atime,$ctime,$pkg,$_,"<RECENT-CTIME>"];
+      }
+      else
+      {
+        # Else we `vote' for the package.
+        $popcon{$pkg}=[$atime,$ctime,$pkg,$_];
       }
-      # Else we `vote' for the package.
-      $popcon{$pkg}=[$atime,$ctime,$pkg,$_,$st];
     }
   }
   close FILES;