Subject: Re: bin/25200: "pax -a" creates archives that "tar" cannot read
To: None <gnats-bugs@gnats.NetBSD.org>
From: Alan Barrett <email@example.com>
Date: 04/16/2004 22:02:25
tar_endwr() [in src/bin/pax/tar.c] writes NULLCNT*BLKMULT bytes of
nulls, but tar_endrd() was recently changed [in revision 1.47] to return
BLKMULT instead of NULLCNT*BLKMULT. This mismatch is apparently the
reason for the bug in PR 25200.
I suspect that tar_endrd() needs to be more clever about detecting
whether the existing archive ended with 1 or 2 blocks of nulls. Perhaps
the value of cnt calculated by tar_trail() could somehow be passed to
tar_endrd() for this purpose, and tar_trail() should probably not lie
about the value of cnt when is_gnutar is true.
--apb (Alan Barrett)