Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re: Net::SCP::Expect causes error in return code

by sierpinski (Chaplain)
on Dec 06, 2010 at 14:23 UTC ( [id://875616]=note: print w/replies, xml ) Need Help??


in reply to Net::SCP::Expect causes error in return code

What is the actual result? I get an error in trying to use /bin/env (bad interpreter)...

Honestly I've never seen that used, but it might be chalked up to ignorance. What result do you get with #!/usr/bin/perl?

Another thing, how are you calling this? I know exec and system have different return values. System returns the return code, and exec doesn't return anything useful (since it either fails (command not found) or never returns (forks to new process)

Edit: typo
  • Comment on Re: Net::SCP::Expect causes error in return code

Replies are listed 'Best First'.
Re^2: Net::SCP::Expect causes error in return code
by cdarke (Prior) on Dec 06, 2010 at 15:21 UTC
    #!/bin/env perl is a common device for using the PATH environment variable to find perl rather than hard-coding the absolute name. I doubt it is relevant.
      Thanks for the info. Learn something new every day!

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others musing on the Monastery: (4)
As of 2024-04-19 17:39 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found