]> git.saurik.com Git - apt.git/blobdiff - apt-pkg/acquire-worker.cc
* apt-pkg/contrib/mmap.{h,cc}:
[apt.git] / apt-pkg / acquire-worker.cc
index 78c68737c32f4d3aef1a37de6314e6b4cfd4d3e8..4f0b52af9739e213d5ef55d578bcbf5250c8f74e 100644 (file)
@@ -527,10 +527,6 @@ bool pkgAcquire::Worker::OutFdReady()
    
    if (Res <= 0)
       return MethodFailure();
-
-   // Hmm.. this should never happen.
-   if (Res < 0)
-      return true;
    
    OutQueue.erase(0,Res);
    if (OutQueue.empty() == true)
@@ -558,7 +554,8 @@ bool pkgAcquire::Worker::MethodFailure()
 {
    _error->Error("Method %s has died unexpectedly!",Access.c_str());
    
-   ExecWait(Process,Access.c_str(),true);
+   // do not reap the child here to show meaningfull error to the user
+   ExecWait(Process,Access.c_str(),false);
    Process = -1;
    close(InFd);
    close(OutFd);