don't double-count seeks in FileFd::Skip for bzip/xz
authorDavid Kalnischkies <david@kalnischkies.de>
Fri, 11 Apr 2014 09:18:58 +0000 (11:18 +0200)
committerDavid Kalnischkies <david@kalnischkies.de>
Fri, 11 Apr 2014 09:18:58 +0000 (11:18 +0200)
FileFd::Read already deals with the increase of the skipposition so that
we as the caller in FileFd::Skip really shouldn't increase it, too.

apt-pkg/contrib/fileutl.cc

index 69a6756..c51f759 100644 (file)
@@ -1712,7 +1712,6 @@ bool FileFd::Skip(unsigned long long Over)
 {
    if (d != NULL && (d->pipe == true || d->InternalStream() == true))
    {
-      d->seekpos += Over;
       char buffer[1024];
       while (Over != 0)
       {