fs/io/FileOutputStream: use CREATE_ALWAYS instead of TRUNCATE_EXISTING

Fixes yet another breakage of creating the database+state file on
Windows.
This commit is contained in:
Max Kellermann 2015-02-10 13:41:09 +01:00
parent 676dfabc91
commit 9c83d3c78c
1 changed files with 1 additions and 1 deletions

View File

@ -39,7 +39,7 @@ FileOutputStream::Create(Path path, Error &error)
FileOutputStream::FileOutputStream(Path _path, Error &error)
:path(_path),
handle(CreateFile(path.c_str(), GENERIC_WRITE, 0, nullptr,
TRUNCATE_EXISTING,
CREATE_ALWAYS,
FILE_ATTRIBUTE_NORMAL|FILE_FLAG_WRITE_THROUGH,
nullptr))
{