summaryrefslogtreecommitdiffstats
path: root/src/corelib/io/qprocess_unix.cpp
diff options
context:
space:
mode:
authorKonstantin Ritt <ritt.ks@gmail.com>2012-04-17 17:07:15 +0300
committerQt by Nokia <qt-info@nokia.com>2012-04-19 15:58:03 +0200
commitd48f3fc1e74f4d489238f511df56a134b53e6a0b (patch)
tree11092fe88e569e16838013ec42a444a965ea5adc /src/corelib/io/qprocess_unix.cpp
parentf4d02ecdbf54987a0bada20fe8f8537e90c051d8 (diff)
fix undefined behavior issue on Integrity
in contrast to ::strdup(), qstrdup() allocates memory via new[]; deallocating this memory with free() leads to undefine behavior. Change-Id: I0692c4bef010c05de547283b00b6c6043ac24c79 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Diffstat (limited to 'src/corelib/io/qprocess_unix.cpp')
-rw-r--r--src/corelib/io/qprocess_unix.cpp7
1 files changed, 0 insertions, 7 deletions
diff --git a/src/corelib/io/qprocess_unix.cpp b/src/corelib/io/qprocess_unix.cpp
index fe13a9e06e..17dae7b6ca 100644
--- a/src/corelib/io/qprocess_unix.cpp
+++ b/src/corelib/io/qprocess_unix.cpp
@@ -117,13 +117,6 @@ QT_BEGIN_NAMESPACE
// so we will use 512
static const int errorBufferMax = 512;
-#ifdef Q_OS_INTEGRITY
-static inline char *strdup(const char *data)
-{
- return qstrdup(data);
-}
-#endif
-
static int qt_qprocess_deadChild_pipe[2];
static struct sigaction qt_sa_old_sigchld_handler;
static void qt_sa_sigchld_handler(int signum)