shared: FileSaver: Don't launch SandboxedProcessor for empty files

This commit is contained in:
Albert S. 2022-06-24 17:44:44 +02:00
parent 614238edda
commit b8006bde7b

View File

@ -124,6 +124,8 @@ SaveFileResult FileSaver::saveFile(const QFileInfo &fileInfo)
}
}
if(fileInfo.size() > 0)
{
QProcess process;
QStringList args;
args << "process" << canonicalPath;
@ -156,6 +158,7 @@ SaveFileResult FileSaver::saveFile(const QFileInfo &fileInfo)
return static_cast<SaveFileResult>(processorReturnCode);
}
}
}
SaveFileResult result = this->dbService->saveFile(fileInfo, pageData);
if(result == OK && processorReturnCode == OK_WASEMPTY)
{