http://www.perlmonks.org?node_id=1083019


in reply to Re: how to transfer a set of files in a directory from linux server(remote machine) to windows server(local machine)
in thread how to transfer a set of files in a directory from linux server(remote machine) to windows server(local machine)

On line 19 you declare my $sftp; but then on line 20 you assign to $stfp = Net::SFTP::Foreign->new. Note the transposition of f and t.

As an aside, this is one the benefits of use strict; it will catch these kinds of spelling errors at compile time.