Bug 91852 - incorrect line counting for output reports
Summary: incorrect line counting for output reports
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: xferstats
Version: 9
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Ngo Than
QA Contact:
Depends On:
TreeView+ depends on / blocked
Reported: 2003-05-28 22:25 UTC by Gilbert E. Detillieux
Modified: 2007-04-18 16:54 UTC (History)
0 users

Clone Of:
Last Closed: 2003-06-03 12:39:15 UTC

Attachments (Terms of Use)
patch to correct multiple bugs related to output line counts (1.58 KB, patch)
2003-05-28 22:26 UTC, Gilbert E. Detillieux
no flags Details | Diff

Description Gilbert E. Detillieux 2003-05-28 22:25:38 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2.1) Gecko/20030113

Description of problem:
There are several logic errors in xferstats-2.16/display.c which affect the
counting of output lines for the reports.  Most affect the daily report, while
one affects multiple other reports.

In most cases, the errors are of the "off by one" variety.  In one case, the
logic is very confusing and just plain wrong.

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. Set "NUMBER_DAILY_STATS 90" and "DAILY_SORT_PREF 2" in /etc/xferstats.cfg
2. Run xferstats with more than 90 days worth of xferlog data.
3. View the resulting daily.html output.

Actual Results:  The output will contain one less line than it should. 
Furthermore, the number of entries per output table (30 by default) will not be
respected - all entries will be in one table.

For other reports, the line count will only be correct for the first table, then
be off by one for subsequent tables.

Expected Results:  Output line counts should be as requested, or as advertized

Additional info:

Comment 1 Gilbert E. Detillieux 2003-05-28 22:26:57 UTC
Created attachment 92043 [details]
patch to correct multiple bugs related to output line counts

Comment 2 Ngo Than 2003-06-03 12:39:15 UTC
2.16-7 has this fix. Thanks for your patch file.

Note You need to log in before you can comment on or make changes to this bug.