Branch Coverage

blib/lib/Net/OpenSSH.pm
Criterion Covered Total %
branch 230 1076 21.3


line true false branch
31 0 0 defined $_ ? :
50 0 0 unpack('c', $c) >= 32 ? :
65 0 6 if (%$opts)
68 0 0 $good ? :
69 0 0 if (@keys)
78 0 0 unless ($wantarray)
85 0 0 if (${^TAINT} > 0)
89 0 0 if (${^TAINT} < 0)
98 0 0 unless $i++
99 0 0 if (&Scalar::Util::tainted($_)) { }
0 0 elsif (ref $_ eq 'HASH') { }
101 0 0 $subn =~ /::([a-z]\w*)$/ ? :
109 0 0 $subn =~ /::([a-z]\w*)$/ ? :
123 1 0 @extra ? :
1 2 $code ? :
126 0 3 if $debug and $debug & 1
137 0 0 if ($@)
148 0 0 unless $self->{'_error'}
171 0 22 unless defined $target
173 0 22 unless ($user, $passwd, $ipv6, $host, $port) = $target =~ m(^ \s* # space (?: ([^:]+) # username (?::(.*))? # : password \@ # @ )? (?: # host ( # IPv6... \[$IPv6_re(?:\%[^\[\]]*)\] # [IPv6] | # or $IPv6_re # IPv6 ) | # or ([^\[\]\@:]+) # hostname / ipv4 ) (?::([^\@:]+))? # port \s* # space $)xi
195 1 21 if (defined $ipv6) { }
203 4 18 unless defined $user
204 22 0 unless defined $port
205 9 13 unless defined $passwd
206 9 13 unless defined $passwd
208 3 19 if wantarray
215 1 18 if defined $ipv6
224 0 3 if ${^TAINT}
227 0 3 if @_ & 1
229 0 3 if defined $FACTORY
235 3 0 unless defined $external_master
237 0 3 if (not defined $opts{'host'} and defined $external_master)
244 3 0 unless (defined $passwd)
247 0 3 if (defined $passwd) { }
260 3 0 unless defined $proxy_command
281 0 3 if $forward_agent and $passphrase
286 3 0 unless defined $passwd_prompt
292 3 0 unless ($external_master)
294 3 0 unless $master_stdout_fh = delete $opts{'master_stdout_fh'}
297 3 0 unless $master_stderr_fh = delete $opts{'master_stderr_fh'}
300 3 0 if (defined $master_opts)
301 3 0 if (ref $master_opts) { }
305 0 0 if $master_opts =~ /^-\w\s+\S/
314 0 3 if $login_handler or defined $passwd
318 0 0 if defined $default_ssh_opts and not ref $default_ssh_opts and $default_ssh_opts =~ /^-\w\s+\S/
327 0 3 delete $opts{'default_stdout_discard'} ? :
329 3 0 unless defined $default_stdout_file
333 0 3 delete $opts{'default_stderr_discard'} ? :
335 3 0 unless defined $default_stderr_file
339 0 3 delete $opts{'default_stdin_discard'} ? :
341 3 0 unless defined $default_stdin_file
348 0 3 if defined $user
349 0 3 if defined $port
356 0 3 if (${^TAINT})
358 0 0 if &Scalar::Util::tainted($ENV{'PATH'})
414 0 2 if defined $default_stdout_file
416 0 2 if defined $default_stderr_file
418 0 2 if defined $default_stdin_file
421 0 2 if ($self->{'_error'} == 3)
432 0 2 if (defined $ctl_path) { }
433 0 0 if ($external_master) { }
434 0 0 unless (-S $ctl_path)
440 0 0 if (-e $ctl_path)
447 0 2 if $external_master
449 2 0 unless (defined $ctl_dir)
450 0 2 unless (defined $self->{'_home'})
459 0 2 unless (-d $ctl_dir)
469 2 0 unless -e $ctl_path
471 0 2 if (-e $ctl_path)
477 0 2 if (defined $sizeof_sun_path and length $ctl_path > $sizeof_sun_path)
483 0 2 if $debug and $debug & 2
485 0 2 if ($strict_mode and not $self->_is_secure_path($ctl_dir))
492 2 0 if $connect
508 0 0 shift @_ ? :
512 0 0 if ${^TAINT}
515 0 0 if $k =~ /^(?:USER|HOST|PORT)$/
524 0 0 $k =~ /^(?:USER|HOST|PORT)$/ ? :
525 0 0 defined $v ? :
530 0 17 if (ref $self and $self->{'_expand_vars'})
532 0 0 length $1 ? :
0 0 if defined $_
536 13 4 wantarray ? :
543 0 0 @_ ? :
0 0 if $ssh->{'_error'}
553 0 0 unless (-d $dir)
554 0 0 if $debug and $debug & 2
558 0 0 if $debug and $debug & 2
559 0 0 unless $uid == $> || $uid == 0 and ($mode & 18) == 0 || $mode & 512
560 0 0 if defined $home and $home eq $dir
567 0 3 if (defined $self->{'_ssh_version'}) { }
568 0 0 if $debug and $debug & 4
580 2 0 if (my($full, $num) = $txt =~ /^OpenSSH_((\d+\.\d+)\S*)/im) { }
581 0 2 if $debug and $debug & 4
586 0 0 if $debug and $debug & 4
593 0 2 unless shift()
597 0 2 @_ ? :
599 0 2 if $debug and $debug & 8
607 0 0 unless $scp =~ s/ssh$/scp/i
614 0 0 unless shift()
618 0 0 defined $self->{'_port'} ? :
621 0 0 if $debug and $debug & 8
628 0 0 if (/['"\s]/)
634 0 0 wantarray ? :
647 0 0 if $debug and $debug & 8
653 0 0 if (@_ == 1)
655 0 0 unless $path =~ m[/]
659 0 0 if (@_ == 2)
667 0 0 unless shift()
670 0 0 if $debug and $debug & 8
683 0 0 @_ ? :
690 0 2 if defined $h and $h ne "IGNORE"
696 0 0 if (my $pid = $self->_my_master_pid) { }
697 0 0 if $debug and $debug & 32
704 0 0 unless $async or __has_sigchld_handle()
706 0 0 if ($self->{'_master_kill_last'} < $now)
709 0 0 unless defined $sig
710 0 0 if $debug and $debug & 32
714 0 0 if $debug and $debug & 32
715 0 0 if $deceased == $pid or $deceased < 0 and $! == 10
716 0 0 if ($self->{'_master_kill_count'} > 20)
718 0 0 if $debug and $debug & 32
721 0 0 if $async
729 0 0 if $debug and $debug & 32
736 0 0 unless @_ <= 2
742 0 0 if (my $pid = $self->_my_master_pid)
743 0 0 if ($self->wait_for_master)
753 0 0 if $self->{'_external_master'}
756 0 0 unless $async
758 0 0 if ($self->{'_master_state'} != "_STATE_GONE")
759 0 0 if $async
773 4 0 unless ($self->{'_external_master'})
776 1 0 if $pid and $self->{'_perl_pid'} == $$ and $self->{'_thread_generation'} == $thread_generation
783 1 0 if $self->{'_master_state'} == "_STATE_GONE"
785 0 0 if (not $async and $self->{'_master_state'} == "_STATE_RUNNING" and $send_ctl || $self->_my_master_pid)
790 0 0 if $debug and $debug & 32
798 3 3 defined $fh ? :
799 6 0 if defined $fn and $fn >= 0
809 0 2 if ($$self{"_master_${name}_discard"}) { }
814 2 0 unless defined $fh
815 0 2 if (defined $fh)
817 0 0 if (fileno $fh != fileno $uname)
818 0 0 unless open $uname, ">>&", $fh
827 2 0 if ($pid) { }
828 0 2 unless defined $timeout
831 2 0 if (defined $timeout and $self->{'_kill_ssh_on_timeout'})
832 0 2 if $self->{'_error'} == 4
835 2 0 unless __has_sigchld_handle()
838 2 0 if (defined $time_limit) { }
842 2 0 if $deceased = waitpid($pid, 1)
844 0 0 if ($remaining <= 0)
845 0 0 if $debug and $debug & 16
852 0 0 $remaining < 0.1 ? :
853 0 0 if $debug and $debug & 16
855 0 0 if $deceased = waitpid($pid, 1)
862 0 2 if $debug and $debug & 16
863 2 0 if ($deceased == $pid) { }
0 0 elsif ($deceased < 0) { }
0 0 elsif ($deceased > 0) { }
864 0 2 if ($?)
867 0 0 if $signal
875 0 0 if $! == 4
876 0 0 if ($! == 10)
898 0 0 if @_
904 0 0 unless @_ <= 2
906 0 0 unless $self->{'_error'} == 1
916 0 0 $self->{'_forward_agent'} ? :
0 2 if defined $self->{'_forward_agent'}
917 0 2 $self->{'_forward_X11'} ? :
920 2 0 $self->{'_ssh_version'} >= 5.6 ? :
925 0 2 if $self->{'_master_pty_force'} or defined $self->{'_login_handler'}
926 0 2 if (defined $self->{'_passwd'}) { }
0 2 elsif ($self->{'_batch_mode'}) { }
929 0 0 $self->{'_passphrase'} ? :
937 0 2 if (defined $self->{'_key_path'})
945 0 2 if (my $gateway_args = $self->{'_gateway_args'})
946 0 0 if (ref $gateway_args eq 'HASH') { }
949 0 0 unless ($gateway = "Net::OpenSSH::Gateway"->find_gateway("errors", $errors, "host", $self->{'_host'}, "port", $self->{'_port'}, %$gateway_args))
959 0 0 unless $gateway->before_ssh_connect
964 0 2 if (defined $proxy_command)
968 0 2 if ($use_pty)
973 0 2 if defined $pref_auths
979 1 1 unless ($pid)
980 0 1 unless defined $pid
983 0 1 if ($debug and $debug & 512)
988 0 1 if $mpty
993 0 1 if defined $self->{'_passwd'}
994 0 1 if defined $self->{'_passphrase'}
996 0 1 if $self->{'_master_setpgrp'}
1009 0 0 if ($async) { }
1010 0 0 if (-S $self->{'_ctl_path'})
1019 0 0 unless ($error)
1021 0 0 if ($out =~ /pid=(\d+)/) { }
1022 0 0 if (not $pid or $1 == $pid)
1029 0 0 $out =~ /illegal option/i ? :
1041 1 0 if ($self->{'_error'} != 1)
1044 0 1 $self->{'_pid'} ? :
1049 0 2 if $debug and $debug & 4
1050 0 0 if ($state == $self->{'_master_state'} and $state != "_STATE_KILLING" and $state != "_STATE_GONE")
1063 1 3 if ($pid)
1065 0 1 if ($deceased == $pid or $deceased < 0 and $! == 10)
1066 0 0 if $debug and $debug & 4
1071 0 4 if ($self->{'_master_state'} == "_STATE_RUNNING")
1072 0 0 if -S $self->{'_ctl_path'}
1076 0 4 if ($self->{'_master_state'} == "_STATE_KILLING")
1077 0 0 if $debug and $debug & 4
1081 2 2 if ($self->{'_master_state'} == "_STATE_START")
1082 0 2 if ($self->{'_external_master'})
1087 0 1 unless $self->_master_start($async)
1088 0 1 if ($self->{'_mpty'})
1091 0 0 if (defined $self->{'_passwd'} or $self->{'_login_handler'})
1098 1 1 if ($self->{'_master_state'} == "_STATE_GONE")
1099 0 1 if (my $mpty = delete $self->{'_mpty'})
1104 0 1 if ($self->{'_master_state'} == "_STATE_STOPPED")
1113 0 1 unless $pid
1117 0 0 if ($self->{'_master_setpgrp'} and not $async and not $self->{'_batch_mode'} and not $self->{'_external_master'})
1120 0 0 if ($old_tcpgrp > 0) { }
1132 0 0 if ($mpty and $self->{'_master_state'} == 2 || $self->{'_master_state'} == 3)
1140 0 1 $async ? :
1146 15 0 if $dt < "0.2"
1147 0 15 if (-e $self->{'_ctl_path'})
1148 0 0 if $debug and $debug & 4
1151 0 15 if $debug and $debug & 4
1153 0 15 if (defined $timeout and time - $start_time > $timeout)
1159 1 14 if ($deceased == $pid or $deceased < 0 and $! == 10)
1162 0 0 $self->{'_passphrase'} ? :
0 1 if defined $self->{'_passwd'}
1167 0 14 if ($self->{'_login_handler'} and $self->{'_master_state'} == 2) { }
1169 0 0 if (eval { do { $self->{'_login_handler'}->($self, $mpty, \$self->{'_wfm_bout'}) } })
1173 0 0 if ($@)
1185 0 14 if ($n > 0)
1186 0 0 unless vec $rv1, $fnopty, 1
1188 0 0 if ($read)
1190 0 0 if ((my $remove = length($self->{'_master_pty_log'}) - 4096) > 0)
1194 0 0 if ($self->{'_wfm_bout'} =~ /The authenticity of host.*can't be established/is)
1200 0 0 if ($self->{'_wfm_bout'} =~ /WARNING: REMOTE HOST IDENTIFICATION HAS CHANGED/is)
1207 0 0 unless ref $passwd_prompt
1209 0 0 if ($self->{'_master_state'} == 2) { }
0 0 elsif (length $passwd_prompt and $self->{'_wfm_bout'} =~ /^(.*$passwd_prompt)\s*$/s) { }
1210 0 0 if ($self->{'_wfm_bout'} =~ /^(.*$passwd_prompt)/s)
1211 0 0 if $debug and $debug & 4
1218 0 0 if $debug and $debug & 4
1226 0 14 if $async
1230 0 1 if (defined $old_tcpgrp)
1231 0 0 if $debug and $debug & 4
1240 1 0 if ($error)
1244 0 0 if $self->_master_jump_state("_STATE_RUNNING", $async)
1250 0 0 ref $_[0] eq 'HASH' ? :
1268 0 0 unless ($self->{'_error'})
1277 3 0 if (pipe $r, $w)
1290 3 0 if (ref $self and !defined($remote_shell) || $remote_shell eq $self->{'_remote_shell'})
1299 0 3 unless ref $opts eq "HASH"
1303 3 0 unless defined $quote
1305 3 0 if ($quote) { }
1308 0 3 $glob_quoting ? :
1314 0 6 if (ref $_) { }
1315 0 0 if (ref $_ eq 'SCALAR') { }
0 0 elsif (ref $_ eq 'REF' and ref $$_ eq 'SCALAR') { }
1331 0 3 if ($quote_extended)
1333 0 0 if ($opts->{'stdout_discard'} and $opts->{'stderr_discard'} || $opts->{'stderr_to_stdout'}) { }
1336 0 0 if $opts->{'stdin_discard'}
1344 3 0 wantarray ? :
1347 0 0 if grep ref($_), @_
1351 0 0 wantarray ? :
1363 0 0 ref $_ eq 'ARRAY' ? :
0 5 defined $_ ? :
1367 0 0 unless $self->wait_for_master
1368 0 0 ref $_[0] eq 'HASH' ? :
1372 0 0 $tty ? :
0 0 if defined $tty
1373 0 0 if ($self->{'_forward_agent'})
1374 0 0 $self->{'_forward_agent'} eq 'always' ? :
1376 0 0 $forward_agent ? :
0 0 if defined $forward_agent
1378 0 0 if ($self->{'_forward_X11'})
1380 0 0 $forward_X11 ? :
1384 0 0 if ($tunnel) { }
1389 0 0 if ($subsystem)
1391 0 0 unless @_ == 1
1397 0 0 if length $ssh_flags
1399 0 0 if (wantarray) { }
1400 0 0 if $debug and $debug & 16
1405 0 0 if $debug and $debug & 16
1412 0 0 ref $name_or_args ? :
1416 0 0 if (open my $fh, $mode, @args) { }
1428 2 1 if (defined $fh)
1431 2 0 if $fn >= $good_fn
1445 0 0 if defined $err_fd
1446 0 0 if (ref $cmd) { }
1469 0 3 if ${^TAINT}
1471 3 0 ref $_[0] eq 'HASH' ? :
1472 0 3 unless (delete $opts{'_no_master_required'})
1473 0 0 unless $self->wait_for_master
1479 0 3 if ($tunnel) { }
1485 0 0 $tty ? :
0 3 if defined $tty
1489 0 3 if not defined $opts{'quote_args_extended'} and $cmd eq "ssh"
1491 0 3 unless $self->_encode_args($argument_encoding, @args)
1496 0 3 if ($stdinout_dpipe) { }
1507 3 0 unless ($stdinout_socket)
1508 0 0 unless ($stdin_discard = delete $opts{'stdin_discard'} or $stdin_pipe = delete $opts{'stdin_pipe'} or $stdin_fh = delete $opts{'stdin_fh'} or $stdin_file = delete $opts{'stdin_file'})
1512 0 0 unless ($tunnel)
1513 0 0 if ($stdin_pty = delete $opts{'stdin_pty'})
1523 0 0 unless $stdout_discard = delete $opts{'stdout_discard'} or $stdout_pipe = delete $opts{'stdout_pipe'} or $stdout_fh = delete $opts{'stdout_fh'} or $stdout_file = delete $opts{'stdout_file'}
1525 0 3 if $stdout_pty and not $stdin_pty
1533 0 3 unless $stderr_discard = delete $opts{'stderr_discard'} or $stderr_pipe = delete $opts{'stderr_pipe'} or $stderr_fh = delete $opts{'stderr_fh'} or $stderr_to_stdout = delete $opts{'stderr_to_stdout'}
1536 3 0 unless defined $ssh_opts
1538 0 3 if ($self->{'_forward_agent'})
1539 0 0 $self->{'_forward_agent'} eq 'always' ? :
1541 0 0 $forward_agent ? :
0 0 if defined $forward_agent
1543 0 3 if ($self->{'_forward_X11'})
1545 0 0 $forward_X11 ? :
1547 0 3 if (delete $opts{'subsystem'})
1552 0 3 if defined $stdin_pty
1556 0 3 if (defined $stdin_file)
1557 0 0 unless $stdin_fh = $self->_open_file("<", $stdin_file)
1559 0 3 if (defined $stdout_file)
1560 0 0 unless $stdout_fh = $self->_open_file(">", $stdout_file)
1562 0 3 if (defined $stderr_file)
1563 0 0 unless $stderr_fh = $self->_open_file(">", $stderr_file)
1568 0 3 if ($stdinout_socket) { }
1569 0 0 unless (socketpair $rin, $win, 1, 1, 0)
1576 0 3 if ($stdin_pipe) { }
0 3 elsif ($stdin_pty) { }
0 3 elsif (defined $stdin_fh) { }
1577 0 0 unless ($rin, $win) = $self->_make_pipe
1582 0 0 unless ($win)
1596 3 0 if ($stdout_pipe) { }
0 0 elsif ($stdout_pty) { }
0 0 elsif (defined $stdout_fh) { }
1597 0 3 unless ($rout, $wout) = $self->_make_pipe
1611 0 3 unless ($stderr_to_stdout)
1612 0 0 if ($stderr_pipe) { }
0 0 elsif (defined $stderr_fh) { }
1613 0 0 unless ($rerr, $werr) = $self->_make_pipe
1624 0 3 if length $ssh_flags
1626 3 0 $cmd eq 'raw' ? :
0 3 $cmd eq 'rsync' ? :
0 3 $cmd eq 'scp' ? :
0 3 $cmd eq 'ssh' ? :
0 3 $tunnel ? :
1633 0 3 if $debug and $debug & 16
1636 1 2 unless ($pid)
1637 0 1 unless (defined $pid)
1643 0 1 if $setpgrp
1645 1 0 if $stdin_discard
1646 0 1 if $stdout_discard
1647 0 1 if $stderr_discard
1649 0 1 if ($stdinout_dpipe)
1651 0 0 unless defined $pid1
1653 0 0 unless ($pid1 xor $stdinout_dpipe_make_parent)
1663 1 0 if (defined $rin_fd)
1664 0 1 if $stdin_pty
1665 0 1 unless $rin_fd == 0 or POSIX::dup2($rin_fd, 0)
1667 1 0 if (defined $wout_fd)
1668 0 1 unless $wout_fd == 1 or POSIX::dup2($wout_fd, 1)
1670 0 1 if (defined $werr_fd) { }
1 0 elsif ($stderr_to_stdout) { }
1671 0 0 unless $werr_fd == 2 or POSIX::dup2($werr_fd, 2)
1674 0 1 unless POSIX::dup2(1, 2)
1679 0 2 if $close_slave_pty
1680 0 2 if defined $stdinout_dpipe
1681 2 0 wantarray ? :
1685 0 0 if ${^TAINT}
1687 0 0 unless $self->wait_for_master
1688 0 0 ref $_[0] eq 'HASH' ? :
1693 0 0 unless $self->_encode_args($argument_encoding, @args)
1695 0 0 if $debug and $debug & 16
1697 0 0 unless ($pid)
1702 0 0 wantarray ? :
1706 0 0 if ${^TAINT}
1708 0 0 unless $self->wait_for_master
1709 0 0 ref $_[0] eq 'HASH' ? :
1714 0 0 unless $self->_encode_args($argument_encoding, @args)
1716 0 0 if $debug and $debug & 16
1718 0 0 unless ($pid)
1723 0 0 wantarray ? :
1728 0 5 if (defined $encoding and $encoding ne "bytes")
1731 0 0 unless (defined $enc)
1743 0 0 if (defined $enc and @_)
1747 0 0 unless defined $_
1751 0 0 unless $self->_check_eval_ok(7)
1757 3 0 if (@_ > 2)
1762 0 3 if ($enc)
1777 0 0 unless defined $_
1792 0 2 unless defined $timeout
1794 0 0 if defined $_
1795 0 2 if ($cin and not $has_input) { }
0 2 elsif (not $cin and $has_input) { }
1796 0 0 unless $keep_in_open
1804 0 2 if ($enc and @data)
1806 0 0 if $has_input
1807 0 0 if $self->{'_error'}
1816 0 2 if $debug and $debug & 64
1820 2 0 if ($cout or $cerr)
1822 2 0 if ($cout)
1826 0 2 if ($cerr)
1832 0 2 if ($cin)
1840 0 4 if $debug and $debug & 64
1845 4 0 if ($n > 0) { }
1846 4 0 if ($cout and vec $rv1, $fnoout, 1)
1849 0 4 if ($debug and $debug & 64)
1851 0 0 if $read and $debug & 128
1853 2 2 unless ($read or grep(($! == $_), @retriable))
1859 0 4 if ($cerr and vec $rv1, $fnoerr, 1)
1861 0 0 if $debug and $debug & 64
1862 0 0 unless ($read or grep(($! == $_), @retriable))
1868 0 4 if ($cin and vec $wv1, $fnoin, 1)
1870 0 0 if ($debug and $debug & 64)
1872 0 0 if $written and $debug & 128
1874 0 0 if ($written) { }
0 0 elsif (grep(($! == $_), @retriable)) { }
1878 0 0 if defined $data[0] and length $data[0]
1886 0 0 unless $keep_in_open
1892 0 0 if $n < 0 and grep(($! == $_), @retriable)
1898 0 2 if $cout
1899 0 2 if $cerr
1900 0 2 if $cin and not $keep_in_open
1902 0 2 if ($enc)
1904 0 0 unless ($self->_decode($enc, $bout, $berr))
1909 0 2 if $debug and $debug & 64
1921 0 0 if ${^TAINT}
1923 0 0 ref $_[0] eq 'HASH' ? :
1933 0 0 if ${^TAINT}
1935 0 0 ref $_[0] eq 'HASH' ? :
1939 0 0 unless my($in, $out, undef, $pid) = $self->open_ex({"stdout_pipe", 1, "stdin_pipe", 1, %opts}, @_)
1951 0 0 if ${^TAINT}
1953 0 0 ref $_[0] eq 'HASH' ? :
1956 0 0 unless my($pty, undef, undef, $pid) = $self->open_ex({"stdout_pty", 1, "stdin_pty", 1, "tty", 1, %opts}, @_)
1961 0 0 wantarray ? :
1969 0 0 if ${^TAINT}
1971 0 0 ref $_[0] eq 'HASH' ? :
1974 0 0 unless my($socket, undef, undef, $pid) = $self->open_ex({"stdinout_socket", 1, %opts}, @_)
1977 0 0 wantarray ? :
1983 0 0 if ${^TAINT}
1985 0 0 ref $_[0] eq 'HASH' ? :
1989 0 0 unless my($in, $out, $err, $pid) = $self->open_ex({"stdout_pipe", 1, "stdin_pipe", 1, "stderr_pipe", 1, %opts}, @_)
2001 0 0 if ${^TAINT}
2003 0 0 ref $_[0] eq 'HASH' ? :
2007 0 0 unless my($pty, undef, $err, $pid) = $self->open_ex({"stdout_pty", 1, "stdin_pty", 1, "tty", 1, "stderr_pipe", 1, %opts}, @_)
2020 0 0 if ${^TAINT}
2022 0 0 ref $_[0] eq 'HASH' ? :
2026 0 0 unless my($socket, undef, $err, $pid) = $self->open_ex({"stdinout_socket", 1, "stderr_pipe", 1, %opts}, @_)
2039 0 0 if ${^TAINT}
2041 0 0 ref $_[0] eq 'HASH' ? :
2045 0 0 $async ? :
2049 0 0 if $stdin_keep_open and not defined $stdin_data
2052 0 0 if (defined $stdin_data)
2061 0 0 unless my($in, undef, undef, $pid) = $self->open_ex(\%opts, @_)
2063 0 0 if defined $stdin_data
2065 0 0 if $async
2077 0 0 if ${^TAINT}
2079 0 0 ref $_[0] eq 'HASH' ? :
2080 0 0 unless grep defined($opts{$_}), ("stdout_discard", "stdout_fh", "stdout_file", "stdinout_dpipe")
2082 0 0 unless grep defined($opts{$_}), ("stderr_discard", "stderr_fh", "stderr_file", "stderr_to_stdout")
2088 0 0 unless ($error)
2091 0 0 if ($error == 5)
2103 0 0 if ${^TAINT}
2105 0 0 ref $_[0] eq 'HASH' ? :
2111 0 0 if $stdin_keep_open and not defined $stdin_data
2115 0 0 if defined $stdin_data
2121 0 0 unless my($in, $out, undef, $pid) = $self->open_ex(\%opts, @_)
2125 0 0 if (wantarray)
2136 0 0 if ${^TAINT}
2138 0 0 ref $_[0] eq 'HASH' ? :
2144 0 0 if $stdin_keep_open and not defined $stdin_data
2149 0 0 if defined $stdin_data
2155 0 0 unless my($in, $out, $err, $pid) = $self->open_ex(\%opts, @_)
2159 0 0 wantarray ? :
2165 0 0 if ${^TAINT}
2167 0 0 ref $_[0] eq 'HASH' ? :
2168 0 0 unless grep defined($opts{$_}), ("stderr_discard", "stderr_fh", "stderr_file")
2170 0 0 unless @_ == 2
2179 0 0 if ${^TAINT}
2181 0 0 ref $_[0] eq 'HASH' ? :
2182 0 0 unless grep defined($opts{$_}), ("stderr_discard", "stderr_fh", "stderr_file")
2184 0 0 unless @_ == 2
2197 0 0 ref $_[0] eq 'HASH' ? :
2199 0 0 unless @_ > 0
2204 0 0 @_ > 1 ? :
2205 0 0 if $target =~ m[^[^/]*:]
2208 0 0 if defined $self->{'_user'}
2217 0 0 if ${^TAINT}
2223 0 0 if ${^TAINT}
2230 0 0 ref $_[0] eq 'HASH' ? :
2232 0 0 unless @_ > 0
2236 0 0 $glob ? :
2239 0 0 if defined $self->{'_user'}
2242 0 0 @_ > 1 ? :
2247 0 0 if ($glob)
2250 0 0 unless (@src)
2262 0 0 if ${^TAINT}
2264 0 0 unless $self
2269 0 0 if ${^TAINT}
2271 0 0 unless $self
2281 0 0 ref $_[0] eq 'HASH' ? :
2283 0 0 unless defined $quiet
2294 0 0 if $ssh_opts
2295 0 0 if $quiet
2296 0 0 if $verbose
2297 0 0 if $recursive
2298 0 0 if $copy_attrs
2299 0 0 if $bwlimit
2309 0 0 if $async
2353 0 0 ref $_[0] eq 'HASH' ? :
2359 0 0 unless defined $quiet or $verbose
2362 0 0 if $quiet
2363 0 0 if $copy_attrs
2364 0 0 $verbose =~ /^\d+$/ ? :
0 0 if $verbose
2371 0 0 if (defined $value)
2372 0 0 if ($rsync_opt_open_ex{$opt}) { }
2378 0 0 if $rsync_opt_forbidden{$opt1}
2379 0 0 if ($rsync_opt_with_arg{$opt1}) { }
2383 0 0 if $opt1 =~ s/^no-//
2384 0 0 $value ? :
2393 0 0 if $async
2394 0 0 if $self->_waitpid($pid, $timeout)
2396 0 0 if ($self->{'_error'} == 5 and $?)
2399 0 0 unless defined $errstr
2401 0 0 $signal ? :
2413 0 0 if ${^TAINT}
2414 0 0 unless @_ & 1
2423 0 0 if defined $fs_encoding and $fs_encoding eq "bytes"
2425 0 0 unless defined $opts{'timeout'}
2426 0 0 unless $self->wait_for_master
2427 0 0 unless my($in, $out, $pid) = $self->open2({"subsystem", 1, "stderr_fh", $stderr_fh, "stderr_discard", $stderr_discard}, "sftp")
2437 0 0 if ($sftp->error)
2447 0 0 if ${^TAINT}
2449 0 0 ref $_[0] eq 'HASH' ? :
2450 0 0 unless @_ == 2
2465 0 0 if ${^TAINT}
2467 0 0 ref $_[0] eq 'HASH' ? :
2468 0 0 unless @_ == 2
2482 0 0 if not defined $hostname && length $hostname or $hostname =~ /^localhost\b/
2490 0 0 unless _load_module("Object::Remote")
2491 0 0 unless _load_module("Net::OpenSSH::ObjectRemote")
2506 0 1 if $debug and $debug & 2