projects
/
apt.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
more refactor
[apt.git]
/
apt-pkg
/
contrib
/
cdromutl.cc
diff --git
a/apt-pkg/contrib/cdromutl.cc
b/apt-pkg/contrib/cdromutl.cc
index 187f6bd5997eb96af56a0b050137094d0d881d69..afa01a56224d790f0cea9242f1976d78a83ff490 100644
(file)
--- a/
apt-pkg/contrib/cdromutl.cc
+++ b/
apt-pkg/contrib/cdromutl.cc
@@
-122,8
+122,9
@@
bool MountCdrom(string Path, string DeviceName)
if (Child == 0)
{
// Make all the fds /dev/null
if (Child == 0)
{
// Make all the fds /dev/null
+ int null_fd = open("/dev/null",O_RDWR);
for (int I = 0; I != 3; I++)
for (int I = 0; I != 3; I++)
- dup2(
open("/dev/null",O_RDWR),
I);
+ dup2(
null_fd,
I);
if (_config->Exists("Acquire::cdrom::"+Path+"::Mount") == true)
{
if (_config->Exists("Acquire::cdrom::"+Path+"::Mount") == true)
{