don't unnecessarily use QFileInfo::filePath()

just directly use the filename we constructed it from.

Change-Id: Ia428a2cb4b192fea6bde62dfbf35361bcfc4b21e
Reviewed-by: Daniel Teske <daniel.teske@digia.com>
(cherry picked from qtcreator/571234786a3ff7e8e3a9220f12d22a9f74f7a53c)
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
This commit is contained in:
Oswald Buddenhagen 2013-05-29 17:12:11 +02:00 committed by The Qt Project
parent 83ee168cbb
commit 4b600bd3c1

View File

@ -315,12 +315,12 @@ QMakeEvaluator::writeFile(const QString &ctx, const QString &fn, QIODevice::Open
return ReturnFalse;
}
QString errStr;
if (!doWriteFile(qfi.filePath(), mode, contents, &errStr)) {
if (!doWriteFile(fn, mode, contents, &errStr)) {
evalError(fL1S("Cannot write %1file %2: %3.")
.arg(ctx, QDir::toNativeSeparators(qfi.filePath()), errStr));
.arg(ctx, QDir::toNativeSeparators(fn), errStr));
return ReturnFalse;
}
m_parser->discardFileFromCache(qfi.filePath());
m_parser->discardFileFromCache(fn);
return ReturnTrue;
}