From 15400d94664f93dc22f71802eb72c34c52e371ac Mon Sep 17 00:00:00 2001 From: Jason McDonald Date: Fri, 26 Aug 2011 17:36:55 +1000 Subject: Send error messages to stderr rather than stdout The commit changes printf's that output error and warning messages to send their text to the stderr stream. Non-error output, such as that produced by passing the -help option to a test, still goes to stdout. Change-Id: Iea4d62451e3e7e84c654859cb09ea7e717511d13 Reviewed-on: http://codereview.qt.nokia.com/3636 Reviewed-by: Qt Sanity Bot Reviewed-by: Rohan McGovern --- src/testlib/qabstracttestlogger.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/testlib/qabstracttestlogger.cpp') diff --git a/src/testlib/qabstracttestlogger.cpp b/src/testlib/qabstracttestlogger.cpp index a5651317e7..d71addb655 100644 --- a/src/testlib/qabstracttestlogger.cpp +++ b/src/testlib/qabstracttestlogger.cpp @@ -76,7 +76,7 @@ void QAbstractTestLogger::startLogging(const char *filename) stream = ::fopen(filename, "wt"); if (!stream) { #endif - printf("Unable to open file for logging: %s", filename); + fprintf(stderr, "Unable to open file for logging: %s", filename); ::exit(1); } } -- cgit v1.2.3