aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorIvan Komissarov <ABBAPOH@gmail.com>2019-11-20 23:34:43 +0900
committerIvan Komissarov <ABBAPOH@gmail.com>2019-11-20 23:42:06 +0000
commit0ce6f93de1cbf702704b776101abb92b3af1cb62 (patch)
tree22f00e4aa6072a416305d83723791496d3b9bfa6 /src
parent36d6566ce7a97556f30628c378037d4162fee8f7 (diff)
Fix -Wunused-but-set-variable on Ubuntu/mingw
Change-Id: I4d837f47f9a2783060fe5832005015ea9adaf5e7 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Diffstat (limited to 'src')
-rw-r--r--src/app/qbs/stdinreader.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/app/qbs/stdinreader.cpp b/src/app/qbs/stdinreader.cpp
index 4f784505d..b90abf9d1 100644
--- a/src/app/qbs/stdinreader.cpp
+++ b/src/app/qbs/stdinreader.cpp
@@ -69,11 +69,11 @@ private:
emit errorOccurred(tr("Cannot read from standard input."));
return;
}
+#ifdef Q_OS_UNIX
const auto emitError = [this] {
emit errorOccurred(tr("Failed to make standard input non-blocking: %1")
.arg(QLatin1String(std::strerror(errno))));
};
-#ifdef Q_OS_UNIX
const int flags = fcntl(0, F_GETFL, 0);
if (flags == -1) {
emitError();