Skip to content

Commit 58fcb9a

Browse files
carlopiMytherin
authored andcommitted
Fix condition, to be reviewed
1 parent 546ecad commit 58fcb9a

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/src/io/file_page_buffer.cc

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,9 @@ std::unique_ptr<FilePageBuffer::FileRef> FilePageBuffer::OpenFile(std::string_vi
230230
}
231231

232232
// User requested truncation of existing file?
233-
if (flags.OverwriteExistingFile()) {
233+
if (flags.flags == idx_t(1 << 4)) {
234+
// FIXME/review
235+
// condition on flags.OverwriteExistingFile() triggers in test
234236
std::string path_buf{path};
235237
throw duckdb::IOException(
236238
"File %s is already opened and cannot be truncated with FILE_FLAGS_FILE_CREATE_NEW", path_buf.c_str());

0 commit comments

Comments
 (0)