Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re^3: Getting back control..to main script

by ELISHEVA (Prior)
on Feb 24, 2011 at 14:33 UTC ( [id://889987]=note: print w/replies, xml ) Need Help??


in reply to Re^2: Getting back control..to main script
in thread Getting back control..to main script

Exec should give you back control. If it didn't we're going to have to brainstorm together and that is quite hard to do with something as vague as "didn't work".

Could you be more precise about what you mean by "didn't work". Didn't work as in "didn't run"? Didn't work as in "didn't get back control"? If you know your script started, how did you know that? What did you see/look for? If you didn't get back control, how did you know that?

At this point, I think it might help if you reduced your code to the smallest possible number of lines that illustrate the problem and then post those lines (preferrably by updating your original post so everyone can see it). How exactly did you make the call to exec? What went before? What came after?

If you are lucky, getting things down to the smallest number of lines that illustrate the problem (and I do mean smallest), might actually tell you why it didn't work. Otherwise, we'll all be in a better position to brainstorm with you.

  • Comment on Re^3: Getting back control..to main script

Replies are listed 'Best First'.
Re^4: Getting back control..to main script
by Ratazong (Monsignor) on Feb 24, 2011 at 14:40 UTC

    From the exec documentation:

    The exec function executes a system command and never returns.
    And when executing the following script
    exec "dir /s d:\\temp\\"; print "done\n"; exit 0;
    I get the warning
    Statement unlikely to be reached at test6.pl line 2. (Maybe you meant system() when you said exec()?)
    So exec isn't likely the correct answer to "getting back control". ;-)

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others chanting in the Monastery: (6)
As of 2024-04-18 07:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found