On Thu, 2008-02-14 at 11:45 -0500, Chris Lewis wrote:
> > unnoticed because the definition of 'me' is redundant.
> 
> It's beginning to look like someone broke config() between the version 
> you're running and mine - I think mine is SVN head.

I'm on r733 ... 

I've updated my copy of the trunk and I'm looking at svn diff -r733 ...
ugh ...

+my %config_dir_memo;
 sub config_dir {
   my ($self, $config) = @_;
+  if (exists $config_dir_memo{$config}) {
+      return $config_dir_memo{$config};
+  }
   my $configdir = ($ENV{QMAIL} || '/var/qmail') . '/control';
   my ($path) = ($ENV{PROCESS} ? $ENV{PROCESS} : $0) =~
m!(.*?)/([^/]+)$!;
   $configdir = "$path/config" if (-e "$path/config/$config");
@@ -128,7 +157,7 @@
     $ENV{QPSMTPD_CONFIG} =~ /^(.*)$/; # detaint
     $configdir = $1 if -e "$1/$config";
   }
-  return $configdir;
+  return $config_dir_memo{$config} = $configdir;
 }

That last change would break it -- the config_dir_memo thing is returned
above.



-- 
--gh


Reply via email to