Fix moveonenospc when file opened with append mode

This commit is contained in:
Antonio SJ Musumeci 2023-06-09 11:58:06 -05:00
parent 701f88de43
commit 82430e1079
5 changed files with 105 additions and 99 deletions

View file

@ -59,7 +59,7 @@ namespace fs
fd = -1;
count = MAX_ATTEMPTS;
flags = (flags_ | O_EXCL | O_CREAT);
flags = (flags_ | O_EXCL | O_CREAT | O_TRUNC);
while(count-- > 0)
{
tmppath = generate_tmp_path(*base_);