summaryrefslogtreecommitdiffstats
path: root/tools/linguist
diff options
context:
space:
mode:
authorOswald Buddenhagen <oswald.buddenhagen@nokia.com>2009-07-30 10:21:22 (GMT)
committerOswald Buddenhagen <oswald.buddenhagen@nokia.com>2009-07-30 14:47:04 (GMT)
commit2ebebeebd3dacc7192f2f998d324d16bc8cba9fa (patch)
treefdc8860ff34c669e0e74f9f5f7d7971478bc9f5e /tools/linguist
parent3ae2cab9c8bd1790a00da2755ac036143a3a35f4 (diff)
downloadQt-2ebebeebd3dacc7192f2f998d324d16bc8cba9fa.zip
Qt-2ebebeebd3dacc7192f2f998d324d16bc8cba9fa.tar.gz
Qt-2ebebeebd3dacc7192f2f998d324d16bc8cba9fa.tar.bz2
fix infinite loop when meeting improper trId()
Diffstat (limited to 'tools/linguist')
-rw-r--r--tools/linguist/lupdate/cpp.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/linguist/lupdate/cpp.cpp b/tools/linguist/lupdate/cpp.cpp
index 58e094b..21b230e 100644
--- a/tools/linguist/lupdate/cpp.cpp
+++ b/tools/linguist/lupdate/cpp.cpp
@@ -1676,7 +1676,9 @@ void CppParser::parseInternal(ConversionData &cd, QSet<QString> &inclusions)
case Tok_trid:
if (!results->tor)
goto case_default;
- if (!sourcetext.isEmpty()) {
+ if (sourcetext.isEmpty()) {
+ yyTok = getToken();
+ } else {
if (!msgid.isEmpty())
qWarning("%s:%d: //= cannot be used with qtTrId() / QT_TRID_NOOP(). Ignoring\n",
qPrintable(yyFileName), yyLineNo);