HCoop
/
ntk
/
apt.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
bef4b14
)
ExtractTar: Allow an empty decompressor program
author
Guillem Jover
<guillem@debian.org>
Sun, 16 Feb 2014 22:29:13 +0000
(23:29 +0100)
committer
Michael Vogt
<mvo@debian.org>
Sat, 22 Feb 2014 19:06:41 +0000
(20:06 +0100)
This allows for uncompressed tar files, as the decompressor process will
not get interposed in-between the file descriptors.
apt-inst/contrib/extracttar.cc
patch
|
blob
|
blame
|
history
diff --git
a/apt-inst/contrib/extracttar.cc
b/apt-inst/contrib/extracttar.cc
index
2437c97
..
41301d1
100644
(file)
--- a/
apt-inst/contrib/extracttar.cc
+++ b/
apt-inst/contrib/extracttar.cc
@@
-111,6
+111,12
@@
bool ExtractTar::Done(bool Force)
gzip will efficiently ignore the extra bits. */
bool ExtractTar::StartGzip()
{
+ if (DecompressProg.empty())
+ {
+ InFd.OpenDescriptor(File.Fd(), FileFd::ReadOnly, FileFd::None, false);
+ return true;
+ }
+
int Pipes[2];
if (pipe(Pipes) != 0)
return _error->Errno("pipe",_("Failed to create pipes"));