in reply to Disconnecting from a Database

I have not looked this up specifically, so I may be wrong.
But this is my thinkging:

$dbh->disconnet does not undefine $dbh, so perl is still holding a valid reference.
It is possible that DBI or DBD is force opening the connection as a default (because the reference is valid).

Admittedly a long shot. But it might be worth checking.