in reply to doubts of a perl beginner in G_EVAL(perlEmbed)

hmm, from perldoc -f exit
Don't use "exit" to abort a subroutine if there's any chance that someone might want to trap whatever error happened. Use "die" instead, which can be trapped by an "eval".

That doesn't sound too promising....

Do you actually need to catch the exit 0, or do you just need to know whether it terminated normally. AFAIK, a zero exit status generally means sucess, whereas anything else means that something went wrong. So perhaps you could just test the exit status of the Perl script, no?

Replies are listed 'Best First'.
Re^2: doubts of a perl beginner in G_EVAL(perlEmbed)
by jithoosin (Scribe) on Dec 26, 2005 at 09:07 UTC
    After reading the first reply i feel i must ask my friend to change the perl code ie exit(0) must be changed to "die".Thanks for the suggestion from the perl doc.