upstream: add test for mux w/-Oproxy; ok djm
OpenBSD-Regress-ID: 764d5c696e2a259f1316a056e225e50023abb027
This commit is contained in:
parent
3d06ff4bbd
commit
c809daaa1b
|
@ -1,4 +1,4 @@
|
||||||
# $OpenBSD: multiplex.sh,v 1.32 2020/01/25 02:57:53 dtucker Exp $
|
# $OpenBSD: multiplex.sh,v 1.33 2020/06/24 15:16:23 markus Exp $
|
||||||
# Placed in the Public Domain.
|
# Placed in the Public Domain.
|
||||||
|
|
||||||
make_tmpdir
|
make_tmpdir
|
||||||
|
@ -97,22 +97,24 @@ kill $netcat_pid 2>/dev/null
|
||||||
rm -f ${COPY} $OBJ/unix-[123].fwd
|
rm -f ${COPY} $OBJ/unix-[123].fwd
|
||||||
|
|
||||||
for s in 0 1 4 5 44; do
|
for s in 0 1 4 5 44; do
|
||||||
trace "exit status $s over multiplexed connection"
|
for mode in "" "-Oproxy"; do
|
||||||
verbose "test $tid: status $s"
|
trace "exit status $s over multiplexed connection ($mode)"
|
||||||
${SSH} -F $OBJ/ssh_config -S $CTL otherhost exit $s
|
verbose "test $tid: status $s ($mode)"
|
||||||
|
${SSH} -F $OBJ/ssh_config -S $CTL $mode otherhost exit $s
|
||||||
r=$?
|
r=$?
|
||||||
if [ $r -ne $s ]; then
|
if [ $r -ne $s ]; then
|
||||||
fail "exit code mismatch: $r != $s"
|
fail "exit code mismatch: $r != $s"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# same with early close of stdout/err
|
# same with early close of stdout/err
|
||||||
trace "exit status $s with early close over multiplexed connection"
|
trace "exit status $s with early close over multiplexed connection ($mode)"
|
||||||
${SSH} -F $OBJ/ssh_config -S $CTL -n otherhost \
|
${SSH} -F $OBJ/ssh_config -S $CTL -n $mode otherhost \
|
||||||
exec sh -c \'"sleep 2; exec > /dev/null 2>&1; sleep 3; exit $s"\'
|
exec sh -c \'"sleep 2; exec > /dev/null 2>&1; sleep 3; exit $s"\'
|
||||||
r=$?
|
r=$?
|
||||||
if [ $r -ne $s ]; then
|
if [ $r -ne $s ]; then
|
||||||
fail "exit code (with sleep) mismatch: $r != $s"
|
fail "exit code (with sleep) mismatch: $r != $s"
|
||||||
fi
|
fi
|
||||||
|
done
|
||||||
done
|
done
|
||||||
|
|
||||||
verbose "test $tid: cmd check"
|
verbose "test $tid: cmd check"
|
||||||
|
|
Loading…
Reference in New Issue