RE: Unparseable replies from GNATS server

"Stuart Stevens" <[email protected]>
Newsgroups gmane.comp.bug-tracking.gnats.general
Message-ID <[email protected]>
Hi

Does anybody have a recommendation on how to add an append-only comments
field?

I would like edits to allow new additions to the field and views to show the
whole field.

Stuart

-----Original Message-----
From: Stuart Stevens [mailto:[email protected]] 
Sent: Wednesday, August 04, 2004 7:49 PM
To: 'Stuart Stevens'; [email protected]
Subject: RE: Unparseable replies from GNATS server



In edit.c, set_field is being called with old_value set to 0x00.



     if ((old_value == NULL && new_value != NULL)
         || (new_value == NULL && old_value != NULL)
         || (new_value != old_value && strcmp (old_value, new_value) != 0))
       {
         /* Ignore changes to readonly fields.  */
         if (fieldDefForIndex (field)->readonly)
           {
             fieldsChanged[x] = 0;
             set_field (new_pr, field, old_value, err);
           }
         else
           {
             fieldsChanged[x] = 1;
           }
       }

 

-----Original Message-----
From: Stuart Stevens [mailto:[email protected]]
Sent: Wednesday, August 04, 2004 5:08 AM
To: 'Stuart Stevens'; [email protected]
Subject: RE: Unparseable replies from GNATS server

I am running GNATS 4.0 on Linux - Red Hat 9.  I pulled the TOT and rebuilt
this morning.  I then run the daemon directly and I got a memory fault.  The
daemon fails with the following field "Comment-new" added to dbconfig:

field "Comments" {
    multitext
    read-only
}

field "Comment-new" {
    multitext
    on-change {
        append-to-field "Comments" {
                "Comment added by %s  on %D\n\n%s"
                "$EditUserEmailAddress" "$CurrentDate" "$NewValue"
        }
    }
    on-change {
        set-field "Comment-new" {
            ""
        }
    }
} 

I issued the following commands:

lock 2511 stuart
editaddr stuart
edit 2511
<email with changes>

Next step is to get into the debugger.

Any ideas?

Thanks
Stuart
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.