diff options
Diffstat (limited to 'src/tools/moc/moc.cpp')
-rw-r--r-- | src/tools/moc/moc.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/tools/moc/moc.cpp b/src/tools/moc/moc.cpp index 03f022da69..e2987f1be4 100644 --- a/src/tools/moc/moc.cpp +++ b/src/tools/moc/moc.cpp @@ -1294,7 +1294,12 @@ void Moc::parsePluginData(ClassDef *def) return; } QFile file(fi.canonicalFilePath()); - file.open(QFile::ReadOnly); + if (!file.open(QFile::ReadOnly)) { + QByteArray msg = "Plugin Metadata file " + lexem() + " could not be opened: " + + file.errorString().toUtf8(); + error(msg.constData()); + return; + } metaData = file.readAll(); } } |