We'll also drop the "\n" for die() to make diagnostics easier.
There's no known bugs in this area, just consistency
improvements and LoC reduction.
$self;
}
-sub _worker_done {
+sub _worker_done { # OnDestroy cb
my ($self) = @_;
- if ($self->need_xapian) {
- die "$$ $0 xdb not released\n" if $self->{xdb};
- }
- die "$$ $0 still in transaction\n" if $self->{txn};
+ die "BUG: $$ $0 xdb active" if $self->need_xapian && $self->{xdb};
+ die "BUG: $$ $0 txn active" if $self->{txn};
}
sub ipc_atfork_child { # called automatically before ipc_worker_loop
sub idx_close {
my ($self) = @_;
- die "transaction in progress $self\n" if $self->{txn};
+ die "BUG: $$ $0 txn active" if $self->{txn};
$self->idx_release if $self->{xdb};
}