Skip Menu |

This queue is for tickets about the Net-SFTP-Foreign CPAN distribution.

Report information
The Basics
Id: 77118
Status: resolved
Worked: 30 min
Priority: 0/
Queue: Net-SFTP-Foreign

People
Owner: Nobody in particular
Requestors: DOUGW [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Critical
Broken in: 1.72_02
Fixed in: (no value)



Password authentication hangs on Unix (solaris). This code: if (waitpid $child, 64 > 0) { has a precedence problem. Should be: if (waitpid($child, 64) > 0) {
On Thu May 10 20:35:01 2012, DOUGW wrote: Show quoted text
> if (waitpid($child, 64) > 0) {
While I was debugging and trying different things, I changed POSIX::WNOHANG() to 64 (that's what it is on solaris). Of course, the code should be: if (waitpid($child, POSIX::WNOHANG()) > 0) {
On Thu May 10 20:40:16 2012, DOUGW wrote: Show quoted text
> > Of course, the code should be: > if (waitpid($child, POSIX::WNOHANG()) > 0) {
And I've only just realized that normally, WNOHANG is 1, and (1 > 0) evaluates to 1, and so the broken version actually works on most OS's :-)
good catch, thank you for reporting it! Also solved in 1.73 (https://metacpan.org/release/SALVA/Net-SFTP-Foreign-1.73).