Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: Perl Script Terminates unexpectedly

by Athanasius (Archbishop)
on Jun 30, 2015 at 07:50 UTC ( [id://1132573]=note: print w/replies, xml ) Need Help??


in reply to Perl Scripts Terminates unexpectedly

Hello gvbals, and welcome to the Monastery!

I take it that you want a quick-and-easy way to find where a given script is terminating. Try adding this to the head of the script:

use Carp; END { confess "Script terminated"; }

The call to Carp::confess will generate a stack trace, which should help you to locate the source of the termination. And the END block will be run even if the script encounters an exit statement.

See Carp and perlmod.

Hope that helps,

Athanasius <°(((><contra mundum Iustus alius egestas vitae, eros Piratica,

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others wandering the Monastery: (6)
As of 2024-04-25 12:31 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found