From 0ad076b1943bf7c65868d1db3cef4bd0ea1ef49a Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Sat, 18 Jul 2020 06:36:32 +0000 Subject: msgmap: fix atfork_* callbacks Noticed while reindexing a largish v2 inbox in parallel on an SSD which required checkpointing and respawning shard workers. Fixes: f06e84220e5566e7 ("over+msgmap: do not store filename after DBI->connect") --- t/msgmap.t | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 't') diff --git a/t/msgmap.t b/t/msgmap.t index f78070cc..1d7d1e87 100644 --- a/t/msgmap.t +++ b/t/msgmap.t @@ -64,4 +64,10 @@ my $tmp = $d->tmp_clone; is_deeply([$d->minmax], [$tmp->minmax], 'Cloned temporary DB matches'); ok($tmp->mid_delete('spam@2'), 'temporary DB is writable'); +is(eval { + $tmp->atfork_prepare; + $tmp->atfork_parent; + 'ok' +}, 'ok', 'atfork_* work on tmp_clone'); + done_testing(); -- cgit v1.2.3-24-ge0c7