Tim,
This patch corrects a problem wherein the contents of the DBI_AUTOPROXY
environment variable affect only the first connect() statement before
getting shunted to the bit bucket by s///. I thought I had sent it to you
a while back, but it doesn't seem to have made it into the code base.
Steve
--- DBI.pm.save Mon May 5 10:23:58 2003
+++ DBI.pm Tue Apr 13 09:38:14 2004
@@ -526,12 +526,13 @@
."and DBI_DSN env var not set");
if ($ENV{DBI_AUTOPROXY} && $driver ne 'Proxy' && $driver ne 'Sponge' && $driver
ne 'Switch') {
+ my $dbi_autoproxy = $ENV{DBI_AUTOPROXY};
my $proxy = 'Proxy';
- if ($ENV{DBI_AUTOPROXY} =~ s/^dbi:(\w*?)(?:\((.*?)\))?://i) {
+ if ($dbi_autoproxy =~ s/^dbi:(\w*?)(?:\((.*?)\))?://i) {
$proxy = $1;
$driver_attrib_spec = ($driver_attrib_spec) ? "$driver_attrib_spec,$2" :
$2;
}
- $dsn = "$ENV{DBI_AUTOPROXY};dsn=dbi:$driver:$dsn";
+ $dsn = "$dbi_autoproxy;dsn=dbi:$driver:$dsn";
$driver = $proxy;
DBI->trace_msg(" DBI_AUTOPROXY:
dbi:$driver($driver_attrib_spec):$dsn\n");
}