mirror of
https://github.com/nextcloud/desktop.git
synced 2024-11-22 13:05:51 +03:00
Vfs suffix: Require suffix when creating placeholder files
This commit is contained in:
parent
3f55f9302e
commit
5e5b0b3f76
1 changed files with 5 additions and 0 deletions
|
@ -63,6 +63,11 @@ void VfsSuffix::createPlaceholder(const SyncFileItem &item)
|
|||
{
|
||||
// The concrete shape of the placeholder is also used in isDehydratedPlaceholder() below
|
||||
QString fn = _setupParams.filesystemPath + item._file;
|
||||
if (!fn.endsWith(fileSuffix())) {
|
||||
ASSERT(false, "vfs file isn't ending with suffix");
|
||||
return;
|
||||
}
|
||||
|
||||
QFile file(fn);
|
||||
file.open(QFile::ReadWrite | QFile::Truncate);
|
||||
file.write(" ");
|
||||
|
|
Loading…
Reference in a new issue