| 172 | } |
| 173 | |
| 174 | static int dump_stack(const char *stackdir, uint32_t hash_id) |
| 175 | { |
| 176 | struct reftable_stack *stack = NULL; |
| 177 | struct reftable_write_options opts = { .hash_id = hash_id }; |
| 178 | struct reftable_merged_table *merged = NULL; |
| 179 | |
| 180 | int err = reftable_new_stack(&stack, stackdir, &opts); |
| 181 | if (err < 0) |
| 182 | goto done; |
| 183 | |
| 184 | merged = reftable_stack_merged_table(stack); |
| 185 | err = dump_table(merged); |
| 186 | done: |
| 187 | if (stack) |
| 188 | reftable_stack_destroy(stack); |
| 189 | return err; |
| 190 | } |
| 191 | |
| 192 | static int dump_reftable(const char *tablename) |
| 193 | { |
no test coverage detected