Commit Graph

6 Commits

Author SHA1 Message Date
Ming-Hung Tsai
27ca8cc009 [block_counter] Add block_counter::clear() 2020-08-17 15:43:09 +08:00
Ming-Hung Tsai
12725983db [block_counter] Add the stop-on-error option to prevent silent errors
The stop-on-error option aims to solve the lack of damage_visitor support
in space_map::count_metadata and btree counting_visitor. To prevent
possibly silent errors during space map or btree counting, the option
stops the counting process immediately when a btree or bitmap error
was found.

The bitmap blocks are also validated to avoid potential false-alarm,
if broken bitmap is not counted, and the corresponding ref-count is
also zeroed.
2020-08-12 15:56:26 +08:00
Ming-Hung Tsai
e62022a200 [base] Move run_set to namespace base 2020-07-29 15:33:25 +08:00
Ming-Hung Tsai
b7d418131d Spin-off syscall-related file operations (#78)
* [file_utils] spin-off syscall-related file operations

1. Eliminate the potential circular dependency between
   persistent-data/block.h and persistent-data/file_utils.h,
   if the former one wants to include the latter.
2. Avoid namespace pollution by removing the "using namespace std"
   declaration in block.tcc.
3. Correct the header hierarchy: base/xml_utils.h now no longer
   depends on the higher-level persistent-data/file_utils.h

* [file_utils] support block files in get_file_length()
2017-04-29 18:51:52 +01:00
Ming-Hung Tsai
d068ec8082 Add utility class binary_block_counter 2016-02-27 15:22:09 +08:00
Joe Thornber
282e98a6b1 Move source into separate sub directories. 2013-01-02 12:55:41 +00:00