refactor: pass copyfile's cleanup flag as a bool

fs::CopyFileFlags is back to a single field since moveonenospc stopped
needing no_replace, and copyfile_stage already takes the same flag as
a bool. Take a bool in both fs::copyfile overloads too, and drop the
FS_COPYFILE_* macros, which nothing uses.
This commit is contained in:
Antonio SJ Musumeci 2026-11-28 00:41:48 -05:00 • committed by Antonio S. Musumeci
parent c49989b75f
commit e954f42751
5 changed files with 21 additions and 29 deletions

View file

@ -3946,7 +3946,7 @@ test_fs_copyfile_basic()
rv = ::pwrite(src_fd,"Z",1,((16 * 1024 * 1024) - 1));
TEST_CHECK(rv == 1);
rv = fs::copyfile(src_fd,dst_path,{.cleanup_failure = true});
rv = fs::copyfile(src_fd,dst_path,true);
TEST_CHECK(rv == 0);
rv = ::fstat(src_fd,&st);
@ -4022,7 +4022,7 @@ test_fs_copyfile_source_changes_cleanup_tmpfiles()
}
});
rv = fs::copyfile(src_fd,dst_path,{.cleanup_failure = true});
rv = fs::copyfile(src_fd,dst_path,true);
stop_mutator.store(true);
mutator.join();