preprocessor: prevent temporary copy

Change-Id: Ic86d8b091da332393a527ba634a23556f2001a8b
Reviewed-by: Thomas Hartmann <Thomas.Hartmann@nokia.com>
This commit is contained in:
hjk
2012-04-17 13:21:47 +02:00
committed by hjk
parent 994cbbb12a
commit 7383220d73

View File

@@ -1171,10 +1171,10 @@ void Preprocessor::handleIncludeDirective(PPToken *tk)
else
return; //### TODO: add error message?
included = included.mid(1, included.size() - 2);
QString inc = QString::fromUtf8(included.constData());
if (m_client)
if (m_client) {
QString inc = QString::fromUtf8(included.constData() + 1, included.size() - 2);
m_client->sourceNeeded(inc, mode, line);
}
}
void Preprocessor::handleDefineDirective(PPToken *tk)