Re: error message with net::FTP



On Thu, 28 Jul 2005 10:17:35 -0400
"Laurent Coudeur" <Laurent_Coudeur@xxxxxxxxxxxxxx> wrote:

> I am having some trouble with net::FTP module
> I get this error message
> Timeout at /usr/lib/perl5/5.8/Net/FTP.pm line 1001
>
> the script list directories in a path
> then loops and list subdirectories
> I can connect and list files but as I try to ls into final sub-directory
> it hangs I get into the directory but cannot list
>
> foreach (@list){
> $ftp->cwd();
> $ftp->cwd("$_");
> my @filelist=$ftp->ls($_) or print LOG "cannot get in project folder
> $_";


I wonder if your $_ is being clobbered, what happens if you try

foreach my $item(@list){
and replace all instances of $_ with $item





Owen
.



Relevant Pages

  • Re: does foreach (@list) alter @list??
    ... Hendrik Maryns wrote: ... > enough I get an error message which says there are uninitialised ... You are using $_ in an outer foreach AND in an inner while. ... Choose some other name for one or the other of the loops. ...
    (comp.lang.perl.misc)
  • error message with net::FTP
    ... the script list directories in a path ... then loops and list subdirectories ...
    (perl.beginners)