[Python-Dev] Re: Problem with 2.3b2 tarfile?

François Pinard pinard@iro.umontreal.ca
30 Jun 2003 17:19:12 -0400


[Jeff Epler]

> the 100-char limit is traditional?

Traditional.  POSIX extends the limit somewhat, but the rules are very
strange.  There are two separated fields in the header, and whenever the
second field is non-empty, a slash is to be _implied_ between both, so you
cannot cut the path string anywhere.

One source of incompatibility from GNU tar came from the fact the FSF staff
used that second field to hold binary information for GNU extensions, like
for sparse files information.  To go over 100 characters, GNU tar used its
own ways.  I remember that while studying these problems in deep detail, I
was dismayed to see than when GNU extensions were added, the guys who did it
already had a copy of the POSIX draft (it was only a draft then), in which
the intent of actually using the second field, was clearly stated.

In any case, I devised a long and careful migration plan (accepted by RMS at
the time) for better POSIX-ifying GNU tar, but I fear this plan has been
abandoned with the change of maintainer.  If I remember correctly, GNU tar
is more or less able to decipher POSIX archives, but you should not rely on
it for generating them in some unusual conditions, like when file names are
long.  But I may be all wrong, as I did not follow recent changes.

-- 
François Pinard   http://www.iro.umontreal.ca/~pinard