diff options
author | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2012-12-01 23:30:27 -0600 |
---|---|---|
committer | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2012-12-01 23:30:27 -0600 |
commit | 7aa5ac7f0e76c5b87e4ca837b75b3edd522a3372 (patch) | |
tree | 9eff0506756adca6934846467804a19f291b4509 /src/kernel/qprocess_unix.cpp | |
parent | bb07131a9191affa4c66f6bc720a388f96343836 (diff) | |
download | qt3-7aa5ac7f0e76c5b87e4ca837b75b3edd522a3372.tar.gz qt3-7aa5ac7f0e76c5b87e4ca837b75b3edd522a3372.zip |
Fix a number of build warnings that could lead to unstable operation
This breaks the ABI
Diffstat (limited to 'src/kernel/qprocess_unix.cpp')
-rw-r--r-- | src/kernel/qprocess_unix.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/kernel/qprocess_unix.cpp b/src/kernel/qprocess_unix.cpp index 2a4a2fd..c6066d4 100644 --- a/src/kernel/qprocess_unix.cpp +++ b/src/kernel/qprocess_unix.cpp @@ -379,7 +379,9 @@ void QProcessManager::sigchldHnd( int fd ) } char tmp; - ::read( fd, &tmp, sizeof(tmp) ); + if (::read( fd, &tmp, sizeof(tmp) ) < 0) { + qWarning( "Could not read from file descriptor" ); + } #if defined(QT_QPROCESS_DEBUG) qDebug( "QProcessManager::sigchldHnd()" ); #endif @@ -562,7 +564,9 @@ QT_SIGNAL_RETTYPE qt_C_sigchldHnd( QT_SIGNAL_ARGS ) return; char a = 1; - ::write( QProcessPrivate::procManager->sigchldFd[0], &a, sizeof(a) ); + if (::write( QProcessPrivate::procManager->sigchldFd[0], &a, sizeof(a) ) < 0) { + qWarning( "Could not write to file descriptor" ); + } } |