We need to bypass whatever Test::More does with END/DESTROY
handlers for use in lon-lived process. This doesn't affect
any of our normal code since we don't use END/DESTROY for
Xapcmd and its callers.
use File::Temp qw(tempdir);
use File::Path qw(remove_tree);
use File::Basename qw(dirname);
+use POSIX ();
# support testing with dev versions of Xapian which installs
# commands with a version number suffix (e.g. "xapian-compact-1.5")
defined(my $pid = fork) or die "fork: $!";
return $pid if $pid > 0;
$cb->($args, $opt);
- exit 0;
+ POSIX::_exit(0);
}
sub runnable_or_die ($) {