Allow to disable zero fill

This commit is contained in:
Vitaliy Filippov
2020-01-06 21:02:15 +03:00
parent bf3eecc159
commit ba23824561
3 changed files with 14 additions and 4 deletions
+4
View File
@@ -10,6 +10,10 @@ void blockstore_impl_t::calc_lengths(blockstore_config_t & config)
{
disable_fsync = true;
}
if (config["zerofill"] == "true" || config["zerofill"] == "1" || config["zerofill"] == "yes")
{
zerofill_enabled = true;
}
// data
data_len = data_size - data_offset;
if (data_fd == meta_fd && data_offset < meta_offset)