On 7/6/07, kapil.V <[EMAIL PROTECTED]> wrote: snip
> 2. can sort of be done*, you can exit a script with exit() (see > perldoc -f exit), die (see perldoc -f die), or croak (see perldoc > Carp). > > * At the end of script any END {} blocks that have been defined will > execute (in reverse order of definition). So far as I know there is > no way to skip the execution of END {} blocks, so you cannot end the > script without *any* further execution. How about `kill -9 $$`? This would bypass the END block unless you have trapped SIGKILL.
snip
That would work, but it is platform specific and not exactly a good thing to do. You could also use the kill function (rather than counting on kill to be in your path. Then it would work on Win32 platforms as well. However, it is generally a good idea to let the END blocks run as they should contain code to clean up the environment (closing network connections, disconnecting from databases, etc). -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/