summaryrefslogtreecommitdiffstats
path: root/tools/configure/environment.cpp
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@nokia.com>2010-08-26 09:31:27 (GMT)
committerThiago Macieira <thiago.macieira@nokia.com>2010-08-26 09:31:27 (GMT)
commit69354f37173b7bfcf7ea0f37175a34b8766afcbb (patch)
treed5d35fbb1c5b93470b6b1aa03c359ac09695055f /tools/configure/environment.cpp
parent065610d14fda00057724a46e2649db6bb98aca58 (diff)
parente5aa5a9d7e97b975316b8cc18554743cccf06474 (diff)
downloadQt-69354f37173b7bfcf7ea0f37175a34b8766afcbb.zip
Qt-69354f37173b7bfcf7ea0f37175a34b8766afcbb.tar.gz
Qt-69354f37173b7bfcf7ea0f37175a34b8766afcbb.tar.bz2
Merge remote branch 'origin/4.6' into qt-4.7-from-4.6
Conflicts: bin/syncqt src/opengl/qgl.cpp tools/configure/configureapp.cpp
Diffstat (limited to 'tools/configure/environment.cpp')
-rw-r--r--tools/configure/environment.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/tools/configure/environment.cpp b/tools/configure/environment.cpp
index 943a8a2..03fd0cc 100644
--- a/tools/configure/environment.cpp
+++ b/tools/configure/environment.cpp
@@ -281,8 +281,7 @@ static QByteArray qt_create_environment(const QStringList &environment)
pos += tmpSize;
}
// add the user environment
- for (QStringList::ConstIterator it = environment.begin(); it != environment.end(); it++ ) {
- QString tmp = *it;
+ foreach (const QString &tmp, environment) {
uint tmpSize = sizeof(wchar_t) * (tmp.length() + 1);
envlist.resize(envlist.size() + tmpSize);
memcpy(envlist.data() + pos, tmp.utf16(), tmpSize);
@@ -386,7 +385,7 @@ int Environment::execute(QStringList arguments, const QStringList &additionalEnv
switch(GetLastError()) {
case E2BIG:
cerr << "execute: Argument list exceeds 1024 bytes" << endl;
- foreach(QString arg, arguments)
+ foreach (const QString &arg, arguments)
cerr << " (" << arg.toLocal8Bit().constData() << ")" << endl;
break;
case ENOENT:
@@ -400,7 +399,7 @@ int Environment::execute(QStringList arguments, const QStringList &additionalEnv
break;
default:
cerr << "execute: Unknown error" << endl;
- foreach(QString arg, arguments)
+ foreach (const QString &arg, arguments)
cerr << " (" << arg.toLocal8Bit().constData() << ")" << endl;
break;
}