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

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??
You said:

I'm trying to execute the unzipper from a command in a popular upload script.

And for some reason, that "unzipper" is named "no-frills.exe". Okay, fine. When I searched your code for "no-frills", I found this line (not quite half-way down, at line #464):

open my $wfh, "| no-frills.exe $uploadedfile";
Then I searched for "$wfh". Wouldn't you know... that variable name occurs only once in your 1K lines of code, at that very line #464. So, you open a pipeline file handle to write to this "unzipper" program, but you never write anything to the file handle -- at least, that's how it is in the posted code.

What would you expect to happen, given that the pipeline file handle receives no input?

BTW, while you're fixing that, you might also want to give the full path name to the program when opening the pipe -- there's no guarantee that the web server process knows where it is (has this program in its execution PATH).


In reply to Re: Can't Get Command Line Unzipper to Execute in CGI/Perl Script by graff
in thread Can't Get Command Line Unzipper to Execute in CGI/Perl Script by socrtwo

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others about the Monastery: (2)
As of 2024-04-26 04:21 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found