[exim-dev] [Bug 2858] New: Adjust output format of "Grand to…

Top Pagina
Delete this message
Reply to this message
Auteur: admin
Datum:  
Aan: exim-dev
Onderwerp: [exim-dev] [Bug 2858] New: Adjust output format of "Grand total summary" for up to 8-digit numbers
https://bugs.exim.org/show_bug.cgi?id=2858

            Bug ID: 2858
           Summary: Adjust output format of "Grand total summary" for up
                    to 8-digit numbers
           Product: Exim
           Version: N/A
          Hardware: All
                OS: All
            Status: NEW
          Severity: wishlist
          Priority: medium
         Component: Eximstats
          Assignee: unallocated@???
          Reporter: fh-exim2003@???
                CC: exim-dev@???


Hi folx,

I just discovered that eximstats outputs the "Grand total summary"
only up to 6-digit number of mails correctly formatted.
(which is apparently not enough for a some mail loops =:)

I suggest to apply the following patch, that will correctly display up
to 8-digit numbers of mails.

diff --git a/src/src/eximstats.src b/src/src/eximstats.src
index 5e1a0847b..c2fcfa57f 100644
--- a/src/src/eximstats.src
+++ b/src/src/eximstats.src
@@ -2640,8 +2640,8 @@ sub print_grandtotals {
     push(@col_headers,"${_}s");
   }


-  my $txt_format1 = "  %-16s %9s     %6d    %6s $sender_txt_format";
-  my $txt_format2 = "  %6d %4.1f%% %6d %4.1f%%",
+  my $txt_format1 = "  %-12s %9s   %8d  %8s $sender_txt_format";
+  my $txt_format2 = "  %8d %4.1f%% %8d %4.1f%%",
   my $htm_format1 = "<tr><td>%s</td><td align=\"right\">%s</td><td
align=\"right\">%s</td><td align=\"right\">%s</td>$sender_html_format";
   my $htm_format2 = "<td align=\"right\">%d</td><td
align=\"right\">%4.1f%%</td><td align=\"right\">%d</td><td
align=\"right\">%4.1f%%</td>";


@@ -2650,8 +2650,8 @@ sub print_grandtotals {
     print $txt_fh "\n";
     print $txt_fh "Grand total summary\n";
     print $txt_fh "-------------------\n";
-    print $txt_fh "                                             
$sender_spaces           At least one address\n";
-    print $txt_fh "  TOTAL               Volume   Messages Addresses
$sender_txt_header      Delayed       Failed\n";
+    print $txt_fh "                                             
$sender_spaces         At least one address\n";
+    print $txt_fh "  TOTAL           Volume   Messages Addresses
$sender_txt_header        Delayed         Failed\n";
   }
   if ($htm_fh) {
     print $htm_fh "<a name=\"Grandtotal\"></a>\n";


--
You are receiving this mail because:
You are on the CC list for the bug.