Merge pull request #149 from msimerson/fortune

fortune: fix bin detection
This commit is contained in:
Matt Simerson 2014-11-14 13:22:45 -08:00
commit 9966c34fd8

View File

@ -6,7 +6,7 @@ use Qpsmtpd::Constants;
sub register {
my $self = shift;
$self->{_fortune} = '/usr/games/fortune';
return if ! $self->{_fortune};
return if ! -x $self->{_fortune};
# if fortune not installed, don't register hook
$self->register_hook('quit', 'fortune');