Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re: scope and undef

by Rhandom (Curate)
on Aug 28, 2007 at 12:46 UTC ( [id://635596]=note: print w/replies, xml ) Need Help??


in reply to scope and undef

At first I thought that it could be a circular ref problem, but then I read his description and that isn't what it sounds like. I would first go with the ->disconnect suggestion. I would then peruse through the code to look to see what other methods the dbh could be getting passed to. Undefing {dbo} or deleting it won't cause a copied reference elsewhere to get DESTROYED. I would guess another object or data structure contains a copy of the dbh - so that you will not be able to rely on implicit object destruction.

You could always call $self->{dbo}->DESTROY but I'm not sure that is best practice. I'd stick with the ->disconnect.

my @a=qw(random brilliant braindead); print $a[rand(@a)];

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://635596]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others rifling through the Monastery: (1)
As of 2024-04-18 23:56 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found