From mboxrd@z Thu Jan 1 00:00:00 1970 From: sohail@techlogix.com To: gnats-gnats@sourceware.cygnus.com Subject: gnats/26: index gets messed up if responsible is empty in categories Date: Sat, 13 Nov 1999 03:44:00 -0000 Message-id: <19991113113836.15226.qmail@sourceware.cygnus.com> X-SW-Source: 1999-q4/msg00050.html List-Id: >Number: 26 >Category: gnats >Synopsis: index gets messed up if responsible is empty in categories >Confidential: no >Severity: serious >Priority: medium >Responsible: unassigned >State: open >Class: sw-bug >Submitter-Id: net >Arrival-Date: Sat Nov 13 03:44:00 PST 1999 >Closed-Date: >Last-Modified: >Originator: Sohail Aslam >Release: 3.113 >Organization: >Environment: Redhat linux 6.0, gnats 3.113, gnatsweb 2.5 >Description: If the reponsible field is left empty, e.g., test:*Test Category:: ^empty here The >Responsible: field in the PR is left empty after the :. This causes the index to get a duplicate entry. Here is how the execution in the gnats code proceeds. In file gen-index.c, the routine do_category calls read_pr to pick up the PR from the PR file. gen-index then calls create_index_entry(line). The character string "line" is passed in which the index entry of the currently read PR is to be returned. Before proceeding, create_index_entry (in file index.c) checks whether the PR has responsible field value. If not, create_index_entry returns immediately. The effect is that the string "line" in do_category retains the index line from the last good PR. The index file ends with a duplicate entry. create_index_entry also returns if ARRIVAL_DATE, LAST_MODIFIED and CLOSED_DATE are found to be empty in the PR. >How-To-Repeat: 1. Set responsible to null (::) for a category. Post a PR. Look at the >Reponsible field in the PR once queue-pr has run. Run gen-index; a duplicate entry will appear. >Fix: gen-index and friends should should take a more appropriate action than to simply return when RESPONSIBLE, CLOSED_DATE, ARRIVAL_DATE and LAST_MODIFIED fields are found to be empty in a PR. >Release-Note: >Audit-Trail: >Unformatted: