cvs commit: qpsmtpd/lib Qpsmtpd.pm

[email protected] (Ask "Bj?rn" Hansen)
Newsgroups perl.cvs.qpsmtpd
Message-ID <[email protected]>
cvsuser     03/08/30 08:14:56

  Modified:    lib      Qpsmtpd.pm
  Log:
    Use $ENV{QMAIL} to override /var/qmail for where to find the
    control/ directory.
  
  Revision  Changes    Path
  1.26      +2 -3      qpsmtpd/lib/Qpsmtpd.pm
  
  Index: Qpsmtpd.pm
  ===================================================================
  RCS file: /cvs/public/qpsmtpd/lib/Qpsmtpd.pm,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -w -r1.25 -r1.26
  --- Qpsmtpd.pm	24 Jul 2003 12:43:46 -0000	1.25
  +++ Qpsmtpd.pm	30 Aug 2003 15:14:56 -0000	1.26
  @@ -53,15 +53,14 @@
     if ($self->{_config_cache}->{$config}) {
       return wantarray ? @{$self->{_config_cache}->{$config}} : $self->{_config_cache}->{$config}->[0];
     }
  -  my $configdir = '/var/qmail/control';
  +  my $configdir = ($ENV{QMAIL} || '/var/qmail') . '/control';
     my ($name) = ($0 =~ m!(.*?)/([^/]+)$!);
     $configdir = "$name/config" if (-e "$name/config/$config");
   
     my $configfile = "$configdir/$config";
   
     if ($type and $type eq "map")  {
  -    warn "MAP!";
  -    return +{} unless -e $configfile;
  +    return +{} unless -e $configfile . ".cdb";
       eval { require CDB_File };
   
       if ($@) {
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.