From df6c4f9a65b12e8ccc15dda068d9258f3fd73aaa Mon Sep 17 00:00:00 2001 From: Marc Mutz Date: Fri, 30 Jan 2015 10:50:49 +0100 Subject: QProcess: fix warnings with QPROCESS_DEBUG defined MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The warnings were: warning: format ‘%d’ expects argument of type ‘int’, but argument 3 has type ‘long int’ [-Wformat=] (2x) Change-Id: If8c2e8fab7388cb4aa7d6e7ceb5faee531e16006 Reviewed-by: Olivier Goffart (Woboq GmbH) --- src/corelib/io/qprocess_unix.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/corelib') diff --git a/src/corelib/io/qprocess_unix.cpp b/src/corelib/io/qprocess_unix.cpp index 63e052094f..014ff12313 100644 --- a/src/corelib/io/qprocess_unix.cpp +++ b/src/corelib/io/qprocess_unix.cpp @@ -761,7 +761,7 @@ qint64 QProcessPrivate::bytesAvailableInChannel(const Channel *channel) const if (::ioctl(channel->pipe[0], FIONREAD, (char *) &nbytes) >= 0) available = (qint64) nbytes; #if defined (QPROCESS_DEBUG) - qDebug("QProcessPrivate::bytesAvailableInChannel(%d) == %lld", channel - &stdinChannel, available); + qDebug("QProcessPrivate::bytesAvailableInChannel(%d) == %lld", int(channel - &stdinChannel), available); #endif return available; } @@ -773,7 +773,7 @@ qint64 QProcessPrivate::readFromChannel(const Channel *channel, char *data, qint #if defined QPROCESS_DEBUG int save_errno = errno; qDebug("QProcessPrivate::readFromChannel(%d, %p \"%s\", %lld) == %lld", - channel - &stdinChannel, + int(channel - &stdinChannel), data, qt_prettyDebug(data, bytesRead, 16).constData(), maxlen, bytesRead); errno = save_errno; #endif -- cgit v1.2.3