[Mimedefang] SA scores
Graham Murray
gmurray at webwayone.co.uk
Thu Oct 19 10:27:41 EDT 2006
"David F. Skoll" <dfs at roaringpenguin.com> writes:
> Graham Murray wrote:
>
>>> There should be a way to query Mail::SpamAssassin for this info.
>
>> Which should not be necessary as if LOCAL_STATE_DIR is not set in the
>> call to Mail::SpamAssassin->new, that function will set it to the
>> correct value.
>
> Really? Could you point out the code that does that?
>From Mail/SpamAssassin.pm. You will notice that it sets the default if
no LOCAL_STATE_DIR is specified in the call.
=item LOCAL_STATE_DIR
Location of the local state directory, mainly used for installing updates via
C<sa-update>. Defaults to "/var/lib/spamassassin".
=back
=cut
sub new {
my $class = shift;
$class = ref($class) || $class;
my $self = shift;
if (!defined $self) { $self = { }; }
bless ($self, $class);
# basic backwards compatibility; debug used to be a boolean.
# translate that into 'all', which is what it meant before 3.1.0.
if ($self->{debug} && $self->{debug} eq '1') {
$self->{debug} = 'all';
}
# enable or disable debugging
Mail::SpamAssassin::Logger::add_facilities($self->{debug});
# first debugging information possibly printed should be the version
dbg("generic: SpamAssassin version " . Version());
# if the libs are installed in an alternate location, and the caller
# didn't set PREFIX, we should have an estimated guess ready, values
# substituted at 'make' time
$self->{PREFIX} ||= '/usr';
$self->{DEF_RULES_DIR} ||= '/usr/share/spamassassin';
$self->{LOCAL_RULES_DIR} ||= '/etc/mail/spamassassin';
$self->{LOCAL_STATE_DIR} ||= '/var/lib/spamassassin';
More information about the MIMEDefang
mailing list