summaryrefslogtreecommitdiffstats
path: root/qmake/main.cpp
diff options
context:
space:
mode:
authorOswald Buddenhagen <oswald.buddenhagen@nokia.com>2009-06-16 07:58:55 (GMT)
committerOswald Buddenhagen <oswald.buddenhagen@nokia.com>2009-06-16 08:15:24 (GMT)
commitfa3d44f7f4dfbf2c6d49af4635231534700d90f4 (patch)
tree2b2a28ac048462bd3f74865cf1a409eeef10d793 /qmake/main.cpp
parent6e022c5c21a44a25b1579f03498ecaeba6da9024 (diff)
downloadQt-fa3d44f7f4dfbf2c6d49af4635231534700d90f4.zip
Qt-fa3d44f7f4dfbf2c6d49af4635231534700d90f4.tar.gz
Qt-fa3d44f7f4dfbf2c6d49af4635231534700d90f4.tar.bz2
disable stdout buffering alltogether
having system-dependent bahavior is Not Nice (TM), and given that we do only printf()s of whole lines anyway, this should have no performance impact whatsoever. Reviewed-by: mariusSO
Diffstat (limited to 'qmake/main.cpp')
-rw-r--r--qmake/main.cpp9
1 files changed, 3 insertions, 6 deletions
diff --git a/qmake/main.cpp b/qmake/main.cpp
index f311699..2295e36 100644
--- a/qmake/main.cpp
+++ b/qmake/main.cpp
@@ -84,14 +84,11 @@ bool qmake_setpwd(const QString &p)
int runQMake(int argc, char **argv)
{
-#ifndef Q_OS_WIN32
// stderr is unbuffered by default, but stdout buffering depends on whether
// there is a terminal attached. Buffering can make output from stderr and stdout
- // appear out of sync, so force stdout to be line buffered to minimize this without
- // hurting performance too much (if at all). This is particularly important for
- // things like QtCreator and scripted builds.
- setvbuf(stdout, (char *)NULL, _IOLBF, 0);
-#endif
+ // appear out of sync, so force stdout to be unbuffered as well.
+ // This is particularly important for things like QtCreator and scripted builds.
+ setvbuf(stdout, (char *)NULL, _IONBF, 0);
// parse command line
int ret = Option::init(argc, argv);