Don't ignore QFile::open() result

PR #22889.
Closes #22888.
This commit is contained in:
Vladimir Golovnev 2025-06-20 10:19:16 +03:00 committed by GitHub
commit e27cbab7ee
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -513,13 +513,13 @@ void SearchPluginManager::updateNova()
const Path enginePath = engineLocation(); const Path enginePath = engineLocation();
QFile packageFile {(enginePath / Path(u"__init__.py"_s)).data()}; QFile packageFile {(enginePath / Path(u"__init__.py"_s)).data()};
packageFile.open(QIODevice::WriteOnly); if (packageFile.open(QIODevice::WriteOnly))
packageFile.close(); packageFile.close();
Utils::Fs::mkdir(enginePath / Path(u"engines"_s)); Utils::Fs::mkdir(enginePath / Path(u"engines"_s));
QFile packageFile2 {(enginePath / Path(u"engines/__init__.py"_s)).data()}; QFile packageFile2 {(enginePath / Path(u"engines/__init__.py"_s)).data()};
packageFile2.open(QIODevice::WriteOnly); if (packageFile2.open(QIODevice::WriteOnly))
packageFile2.close(); packageFile2.close();
// Copy search plugin files (if necessary) // Copy search plugin files (if necessary)