summaryrefslogtreecommitdiff
path: root/apt-pkg/deb/dpkgpm.cc
diff options
context:
space:
mode:
Diffstat (limited to 'apt-pkg/deb/dpkgpm.cc')
-rw-r--r--apt-pkg/deb/dpkgpm.cc5
1 files changed, 4 insertions, 1 deletions
diff --git a/apt-pkg/deb/dpkgpm.cc b/apt-pkg/deb/dpkgpm.cc
index 92f96620f..3235b0b06 100644
--- a/apt-pkg/deb/dpkgpm.cc
+++ b/apt-pkg/deb/dpkgpm.cc
@@ -841,8 +841,11 @@ bool pkgDPkgPM::Go(int OutStatusFd)
signal(SIGQUIT,old_SIGQUIT);
signal(SIGINT,old_SIGINT);
- if(master >= 0 && slave >= 0)
+ if(master >= 0)
+ {
tcsetattr(0, TCSAFLUSH, &tt);
+ close(master);
+ }
// Check for an error code.
if (WIFEXITED(Status) == 0 || WEXITSTATUS(Status) != 0)