| 6115 | } |
| 6116 | |
| 6117 | static void *racing_sweep_thread(void *arg) { |
| 6118 | racing_sweep_arg_t *a = (racing_sweep_arg_t *)arg; |
| 6119 | cbm_pipeline_t *p = cbm_pipeline_new(a->tmp_dir, a->db_path, CBM_MODE_FULL); |
| 6120 | if (p) { |
| 6121 | /* Its own sweep_orphan_stages() runs at the very start, before this |
| 6122 | * run mints its own stage -- exactly like the first run's. Cancel |
| 6123 | * immediately: this run must reach the sweep and nothing past it. */ |
| 6124 | cbm_pipeline_cancel(p); |
| 6125 | (void)cbm_pipeline_run(p); |
| 6126 | cbm_pipeline_free(p); |
| 6127 | } |
| 6128 | return NULL; |
| 6129 | } |
| 6130 | |
| 6131 | /* Fired from inside the FIRST run's create_staging_path(), the instant its |
| 6132 | * stage main file exists (under the fix, with its sidecar lock already held; |
nothing calls this directly
no test coverage detected