}
}
+{
+ package Local::Exception::package_configuration;
+ {our @ISA = qw(Local::Exception)}
+
+ sub package_name { (shift)->{package_name} }
+}
+
{
package Local::Exception::directive_syntax;
{our @ISA = qw(Local::Exception)}
$Phase = 'AA';
# Check that we have a keyring for this package:
my @keyrings = directory_keyrings($op_header->{directory});
- fatal("no keyring for package $op_header->{package}",0) if ($#keyrings < 0);
+ unless (@keyrings) {
+ my $package = directory_package_name($op_header->{directory});
+ throw package_configuration =>
+ summary => "no keyring for package $package",
+ package_name => directory_package_name($op_header->{directory})
+ }
$sig_info = verify_clearsigned_message($directive_text, @keyrings);
mail($E->{message},$E->{send_to_user});
} elsif ($E->type_p('directive_syntax')) {
mail(join("\n",$E->{summary},'',$E->trace_msg),1);
+ } elsif ($E->type_p('package_configuration')) {
+ mail($E->{summary},0);
}
} else {
# Exceptions thrown by perl itself come out as strings