BUG: bundle testament: something wrong again

Jan Hudec bulb at ucw.cz
Tue Jul 11 20:41:30 BST 2006


On Tue, Jul 11, 2006 at 16:35:49 +0300, Alexander Belchenko wrote:
> Aaron Bentley пишет:
> >
> >>As I understand another solution for this problem (and this was
> >>discussed before, IIRC) is to make diff inside bundle only for review
> >>and store *all* actual revision text inside base-64 encoded section.
> >
> >
> >Yes.  This solution doesn't sit right with me, especially because it
> >would require a binary section even when the bundle only has a single
> >revision.
> 
> I understand.

I think, that altering anything with Content-Disposition: attachment is a bug
in Thunderbird in the first place. Though patches are the only kind of files
I can think of where it actually hurts (note: PGP skips whitespace when
computing the checksum, though if you do checksums with md5 and sign these,
it will hurt as well). Note, that it hurts even normal patches, because patch
considers extra/missing ^M in the contex a mismatch.

> >It would also be possible to declare the line-ending type of each patch.
> 
> It's nice idea. I think it require to implement universal line-endings
> support in bzr first. And this support (I think) should store all text
> files in repo with LF line-endings only and additionally store in
> inventory type of actual line-endings (as at this moment we store
> executable flag in inventory).

The diff in bundle is between repository-format files, so it would have LF
line-endings than.

> But... It won't work if file itself has mix of line-endings and
> inventory does not know what line-endings actually should be. It's very
> bad occasion for all reasons, but sometimes (0.000....001%) it may happens.

User may just require to preserve them. And bzr must cope. 

There are some not-so-uncommon situations where this is required:
 - Network line-endings for both mail and web is CRLF, but often the actual
   content is LF-only. So if you store whole mail message, it's often mixed.
   There is at least one application -- bugs everywhere -- that stores raw
   mailbox files in bzr.
 - For similar reason if you can have code using LF-only with embedded
   literals canned for transmission using CRLF.
 - Patches for CRLF files. Eg. Debian packages usually contain patches and if
   it's a dual-platform package and upstream uses CRLF, than the patches are
   mixed.

-- 
						 Jan 'Bulb' Hudec <bulb at ucw.cz>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20060711/1e89f412/attachment.pgp 


More information about the bazaar mailing list