summaryrefslogtreecommitdiffstats
path: root/qmake/library/qmakeparser.cpp
diff options
context:
space:
mode:
authorOswald Buddenhagen <oswald.buddenhagen@digia.com>2013-07-24 19:45:58 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-08-20 22:56:07 +0200
commit15981b985fa3ae250af22f68ddb50e08bd9ce421 (patch)
tree107c6d677617184f9e546d52a7c1cc6993d8e6a3 /qmake/library/qmakeparser.cpp
parent0a1faaa9eb7807bf11d796c2eca624e2f3b378a7 (diff)
complain about absent files to -pro argument (in lupdate)
this doesn't actually do anything in qmake. Change-Id: I908fc3792bdc321370e51be98adf7a9c81e37a85 Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com> (cherry picked from qttools/e1f3732197ef77a29cb7f3c1ce094b3f31a7b689) (cherry picked from qttools/226f013441990aa4a58f7c82e284057cff659959)
Diffstat (limited to 'qmake/library/qmakeparser.cpp')
-rw-r--r--qmake/library/qmakeparser.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/qmake/library/qmakeparser.cpp b/qmake/library/qmakeparser.cpp
index 67594625dc..0de3804764 100644
--- a/qmake/library/qmakeparser.cpp
+++ b/qmake/library/qmakeparser.cpp
@@ -184,7 +184,7 @@ ProFile *QMakeParser::parsedProFile(const QString &fileName, ParseFlags flags)
locker.unlock();
#endif
pro = new ProFile(fileName);
- if (!read(pro)) {
+ if (!read(pro, flags)) {
delete pro;
pro = 0;
} else {
@@ -205,7 +205,7 @@ ProFile *QMakeParser::parsedProFile(const QString &fileName, ParseFlags flags)
}
} else {
pro = new ProFile(fileName);
- if (!read(pro)) {
+ if (!read(pro, flags)) {
delete pro;
pro = 0;
}
@@ -230,12 +230,12 @@ void QMakeParser::discardFileFromCache(const QString &fileName)
m_cache->discardFile(fileName);
}
-bool QMakeParser::read(ProFile *pro)
+bool QMakeParser::read(ProFile *pro, ParseFlags flags)
{
QString content;
QString errStr;
if (!m_vfs->readFile(pro->fileName(), &content, &errStr)) {
- if (m_handler && m_vfs->exists(pro->fileName()))
+ if (m_handler && ((flags & ParseReportMissing) || m_vfs->exists(pro->fileName())))
m_handler->message(QMakeParserHandler::ParserIoError,
fL1S("Cannot read %1: %2").arg(pro->fileName(), errStr));
return false;