help-gnats
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Gnatsweb attachment handling broken by gnatsd


From: Milan Zamazal
Subject: Re: Gnatsweb attachment handling broken by gnatsd
Date: 22 Apr 2001 18:27:39 +0200
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.0.102

[Sorry for the long delay in answer.]

>>>>> "YS" == Yngve Svendsen <address@hidden> writes:

    YS> The handling of attachments by Gnatsweb currently seems to be
    YS> broken, and this seems to be due to a "feature" in
    YS> gnatsd. Gnatsweb stores attachments in the "Unformatted" field,
    YS> and according to the GNATS ChangeLog:

    YS> Tue Feb 1 17:47:45 2000 Bob Manson <address@hidden>

    YS>          * pr.c (addLineToPR): Add spaces to the beginning of
    YS> Unformatted: field entries if they don't have one already.
    YS> Ignore text that looks like a field name if it isn't a valid
    YS> name.

    YS> This means that every line of data in the "Unformatted" field
    YS> gets a leading space, and this breaks Gnatsweb's functions for
    YS> decoding and handling attachments by embedding them in the PR
    YS> data.

    YS> Now, the question is: why was this "feature" added to gnatsd in
    YS> the first place? Anynone care to take a look and see what they
    YS> think?

I think it's there because unknown fields are added there and they
should be prevented looking like real fields, they should be a clear
part of the `Unformatted' field.

    YS> By doing the following to addLineToPR in pr.c (basically
    YS> commenting out the space-adding code) and rebuilding gnatsd,
    YS> attachment handling worked again:

I don't think doing this is a good idea.

    YS> The easiest way to fix Gnatsweb would be to remove this code
    YS> from pr.c. Working around it in Gnatsweb would take a bit of
    YS> coding and very likely affect performance a lot.

As it was already suggested, it's likely that attachements will be
handled in a special way in GNATS 4.x.  As for GNATS 4.0, I think
Gnatsweb should be fixed.  I don't know anything about the attachement
handling in Gnatsweb, but I think it's not a good ideat to store them in
the `Unformatted' field.  I'd suggest considering to require having the
`Attachement' field in `dbconfig' (I might add it to the default
`dbconfig' if it proves useful).

Regards,

Milan Zamazal

-- 
Free software is about freedom, not about free beer.  If you care only about
the latter, you'll end with no freedom and no free beer.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]