I have, that's how I worked out it was an unexpected EOF!

I don't have the log file available to post as I've gone and deleted it before running another version of the program which as yet hasn't gone wrong, however the bit of code reads like this...

It gets the file and returns 0 if okay, otherwise the it returns code from the server. It doesn't delete yet to move files from the FTP server, it just copies at the moment, and it doesn't cope with EOFs...

$exempt is 421 if I want it to try again later with a timeout...

sub ftp_move() { my $exempt=-1; my $code; $exempt=$_[0] if $_[0]; &write_log("+ [$filename] interesting name, moving to incoming + directory.",0); if($ftp->get($filename,$rvf_incoming.$filename)) { $files_moved++; return 0; } $code=$ftp->code; if($code>=400) { &write_log("| [$filename] error getting from FTP site +- ".$code." $@",0) if $code!=$exempt; $files_error++ if $code!=$exempt; return $code; } return 0; }

In reply to Re: Re: NET::FTP - Unexpected EOF on command channel by Anonymous Monk
in thread NET::FTP - Unexpected EOF on command channel by Anonymous Monk

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



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.