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

Re: Bug#494714: dpkg-dev - dpkg-genchanges should fold lines



On Fri, May 15 2009, Russ Allbery wrote:

> Raphael Hertzog <hertzog@debian.org> writes:
>
>> CCing -policy, do we need to update policy to allow Binary: fields
>> over multiple lines?
>
> Yes.  (But I certainly have no objections to doing so.)
>
>> Currently it only says that the fields are comma-separated and
>> space-separated. Does "space" include newlines like in the usual \s
>> perl regexp or not ?
>
> No.
>
> This needs to be clarified in Policy in general, since it's been
> confusing to people in several different contexts.


        It is my recollection that each field in the control file (and
 perhaps others) was supposed to follow rfc822 (now rfc5322), and that
 says:
,----
|    Each header field is logically a single line of characters comprising
|    the field name, the colon, and the field body.  For convenience
|    however, and to deal with the 998/78 character limitations per line,
|    the field body portion of a header field can be split into a
|    multiple-line representation; this is called "folding".  The general
|    rule is that wherever this specification allows for folding white
|    space (not simply WSP characters), a CRLF may be inserted before any
|    WSP.
|
|   The process of moving from this folded multiple-line representation
|   of a header field to its single line representation is called
|   "unfolding".  Unfolding is accomplished by simply removing any CRLF
|   that is immediately followed by WSP.  Each header field should be
|   treated in its unfolded form for further syntactic and semantic
|   evaluation.  An unfolded header field has no length restriction and
|   therefore may be indeterminately long.
`----

        So, each filed is always one logical line, but may consist of
 multiple physical lines.

        I suggest we add explanation like this to the policy document.

        manoj
-- 
The Finagle Factor is characterized by changing the Universe to fit the
equation.
Manoj Srivastava <srivasta@debian.org> <http://www.debian.org/~srivasta/>  
1024D/BF24424C print 4966 F272 D093 B493 410B  924B 21BA DABB BF24 424C


Reply to: