ContextualFetch 1.02 steps on $DBI::errstr
[prev]
[thread]
[next]
[Date index for 2005/04/19]
I hope I'll gain a little more traction on this one than on my complaint ab=
out
the behavior of validate_column_values :-)
If you connect with RaiseError =3D 0 and PrintError 1, ContextualFetch over=
writes
the errstr setting when it resets the Taint attribute of the handle. That i=
s,
# local $sth->{Taint} leaks in old perls :(
sub _untaint_execute {
=09my $sth =3D shift;
=09my $old_value =3D $sth->{Taint};
=09$sth->{Taint} =3D 0;
=09my $ret =3D $sth->SUPER::execute(@_);
#>>> $DBI::errstr might be set here...
=09$sth->{Taint} =3D $old_value;
#>>> but now it's gone
=09return $ret;
}
While I much prefer RaiseError =3D 1, I'm integrating with an existing
code base where that's not an option. The only way I can see to
override this behavior is to write my own DBI root class inherited
from ContextualFetch to fix it, but that seems a bit gross. Am I
missing something here?
Rod
|
|
ContextualFetch 1.02 steps on $DBI::errstr
Rod McChesney 02:40 on 19 Apr 2005
|