develooper Front page | perl.perl5.porters | Postings from September 2012

[perl #113390] Net::FTP notice read() error on local file

Thread Previous
From:
James E Keenan via RT
Date:
September 3, 2012 06:12
Subject:
[perl #113390] Net::FTP notice read() error on local file
Message ID:
rt-3.6.HEAD-11172-1346677953-1694.113390-15-0@perl.org
On Sat May 26 16:44:40 2012, kryde wrote:
> In Net::FTP version 2.77, when doing a put() if there's an error from
> read() it seems to be silently treated as normal eof, where I hoped it
> would gives some sort of error.
> 
> I see the code notices an error from binmode(), or socket write() and
> close(), and gives an undef return, but apparently not for read()
> trouble.
> 
> The foo.pl below simulates a read error with a tied file handle.
> I wonder if the $ftp->put() could return undef in this case.
> 

So far I am unable to confirm the problem because I cannot get 'foo.pl'
to complete on either of two platforms at my disposal.

On Darwin/PPC, the program dies here:

#####
Cannot connect: Net::FTP: connect: Invalid argument at 113390_foo.pl
line 24.
#####

On Linux/i386, the program dies here:

#####
Cannot cwd: /pub: No such file or directory
 at 113390_foo.pl line 30.
#####

Can you (or anyone) supply a different example?

Thank you very much.
Jim Keenan


---
via perlbug:  queue: perl5 status: new
https://rt.perl.org:443/rt3/Ticket/Display.html?id=113390

Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About