package Forker; #... sub forker { die "fork failed: $!" unless defined( my $pid = fork ); return if $pid; # break a leg kill 9, $$; }