diff options
Diffstat (limited to 'qmake/library/qmakeparser.cpp')
-rw-r--r-- | qmake/library/qmakeparser.cpp | 8 |
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; |