summaryrefslogtreecommitdiffstats
path: root/src/bftw.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/bftw.c')
-rw-r--r--src/bftw.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/bftw.c b/src/bftw.c
index 69e41a2..2bdf12d 100644
--- a/src/bftw.c
+++ b/src/bftw.c
@@ -1147,6 +1147,10 @@ static int bftw_gc(struct bftw_state *state, enum bftw_gc_flags flags) {
static int bftw_state_destroy(struct bftw_state *state) {
dstrfree(state->path);
+ if (state->ioq) {
+ ioq_cancel(state->ioq);
+ }
+
SLIST_EXTEND(&state->files, &state->batch);
do {
bftw_gc(state, BFTW_VISIT_NONE);