CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Perl Programming Help: Beginner:
Strange error message in perl , when closing Oracle connection

 



digioleg54
User

Apr 28, 2017, 1:55 PM

Post #1 of 2 (688 views)
Strange error message in perl , when closing Oracle connection Can't Post

 
when I call sub close_and_exit below



Code
   
sub close_and_exit {
my ($ref_dbh) = @_;
&print_html_header("CLOSE_AND_EXIT");
if (defined($ref_dbh) && defined($$ref_dbh)) {
$$ref_dbh->disconnect;
undef($$ref_dbh);
}
&print_html_trailer;
(defined($auth_dbh)) && ($auth_dbh->disconnect());
exit(0);
}



there is a message:




Code
  


Issuing rollback() due to DESTROY without explicit disconnect() of DBD::Oracle::db handle orfissp at /vhosts/dw18637/lib/web/dteacl_b.pl line 241.




Line 241 is exit(0);
Could you please tell me why?

Thanks


(This post was edited by digioleg54 on Apr 28, 2017, 1:55 PM)


FishMonger
Veteran / Moderator

Apr 29, 2017, 8:55 AM

Post #2 of 2 (673 views)
Re: [digioleg54] Strange error message in perl , when closing Oracle connection [In reply to] Can't Post

This conditional probably evaluated to false.

Code
if (defined($ref_dbh) && defined($$ref_dbh)) {

Therefore the disconnect statement was not executed.

Or, this defined statement evaluated to false.

Code
(defined($auth_dbh)) && ($auth_dbh->disconnect());

Which would prevent that disconnect statement from executing.

 
 


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives