[Bug-tar] Warning from tar via dpkg

From:

Daniel Macks

Subject:

[Bug-tar] Warning from tar via dpkg

Date:

Wed, 13 Dec 2006 20:19:23 -0500

User-agent:

Mutt/1.4.2.1i

dpkg-deb uses tar internally to create a .deb archive:
execlp(TAR,"tar","-cf", "-", "-T", "-", "--null", "--no-recursion", (char*)0);
When I upgraded my tar from 1.15.1 to 1.16.1, that command started
giving a warning:
tar: -: file name read contains nul character
that I've never seen before. I don't see any real documentation about
it, except for two NEWS items from 1.15.90:
** Any number of -T (--files-from) options may be used in the command line.
The file specified with -T may include any valid `tar' options,
including another -T option.[...]
** List files containing null-separated file names are detected and processed
automatically. It is no longer necessary to give the --null option.
Another user has reported that the warning can be averted by patching:
execlp(TAR,"tar","-cf", "-", "--null", "-T", "-", "--null", "--no-recursion",
(char*)0);
So first a question: is it true that that's the correct patch for
compatibility with the new tar? Not too hard for me (and fink) to
patch our dpkg to use this new syntax if it's correct and likely to
remain silently compatible into the reasonable future.
And second a comment: seems suboptimal to make a commonly-used
invocation (every time a debian user builds a binary) suddently start
issuing warnings. I'm sure there's a reason, but it's an annoying
growing pain of sorts.
dan
--
Daniel Macks
address@hidden
http://www.netspace.org/~dmacks