summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@nokia.com>2009-07-28 08:56:12 (GMT)
committerThiago Macieira <thiago.macieira@nokia.com>2009-07-28 14:07:56 (GMT)
commit3a0eccfe7237fe69e41580d1fb780342f4c09691 (patch)
treef643fc6296138cbd20c53b2dbb060d72df9b75c8 /src
parent745e12297f0133a6bd54e2809540c47370b405a5 (diff)
downloadQt-3a0eccfe7237fe69e41580d1fb780342f4c09691.zip
Qt-3a0eccfe7237fe69e41580d1fb780342f4c09691.tar.gz
Qt-3a0eccfe7237fe69e41580d1fb780342f4c09691.tar.bz2
Fix startDetached: the pipes must be CLOEXEC for them to work.
In de05f9a40e41deb79daf5c4935b2645d70d7f322 I removed the fcntl that set FD_CLOEXEC because it was supposed to be set by qt_safe_pipe. Turns out that this code didn't call the wrapper function... Reviewed-by: ossi
Diffstat (limited to 'src')
-rw-r--r--src/corelib/io/qprocess_unix.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/corelib/io/qprocess_unix.cpp b/src/corelib/io/qprocess_unix.cpp
index fafce07..607b734 100644
--- a/src/corelib/io/qprocess_unix.cpp
+++ b/src/corelib/io/qprocess_unix.cpp
@@ -1161,10 +1161,10 @@ bool QProcessPrivate::startDetached(const QString &program, const QStringList &a
// To catch the startup of the child
int startedPipe[2];
- ::pipe(startedPipe);
+ qt_safe_pipe(startedPipe);
// To communicate the pid of the child
int pidPipe[2];
- ::pipe(pidPipe);
+ qt_safe_pipe(pidPipe);
pid_t childPid = qt_fork();
if (childPid == 0) {