mirror of
https://github.com/yuzu-emu/mbedtls.git
synced 2024-11-25 17:25:37 +01:00
Merge pull request #3404 from mpg/improve-ssl-opt-logs
Improve ssl-opt.sh logs
This commit is contained in:
commit
98944cd756
@ -1232,7 +1232,7 @@ run_client() {
|
||||
cp $CLI_OUT c-cli-${TESTS}.log
|
||||
echo " ! outputs saved to c-srv-${TESTS}.log, c-cli-${TESTS}.log"
|
||||
|
||||
if [ "X${USER:-}" = Xbuildbot -o "X${LOGNAME:-}" = Xbuildbot -o "${LOG_FAILURE_ON_STDOUT:-0}" != 0 ]; then
|
||||
if [ "${LOG_FAILURE_ON_STDOUT:-0}" != 0 ]; then
|
||||
echo " ! server output:"
|
||||
cat c-srv-${TESTS}.log
|
||||
echo " ! ==================================================="
|
||||
|
@ -445,7 +445,7 @@ fail() {
|
||||
fi
|
||||
echo " ! outputs saved to o-XXX-${TESTS}.log"
|
||||
|
||||
if [ "X${USER:-}" = Xbuildbot -o "X${LOGNAME:-}" = Xbuildbot -o "${LOG_FAILURE_ON_STDOUT:-0}" != 0 ]; then
|
||||
if [ "${LOG_FAILURE_ON_STDOUT:-0}" != 0 ]; then
|
||||
echo " ! server output:"
|
||||
cat o-srv-${TESTS}.log
|
||||
echo " ! ========================================================"
|
||||
@ -697,6 +697,19 @@ run_test() {
|
||||
return
|
||||
fi
|
||||
|
||||
# update DTLS variable
|
||||
detect_dtls "$SRV_CMD"
|
||||
|
||||
# if the test uses DTLS but no custom proxy, add a simple proxy
|
||||
# as it provides timing info that's useful to debug failures
|
||||
if [ -z "$PXY_CMD" ] && [ "$DTLS" -eq 1 ]; then
|
||||
PXY_CMD="$P_PXY"
|
||||
case " $SRV_CMD " in
|
||||
*' server_addr=::1 '*)
|
||||
PXY_CMD="$PXY_CMD server_addr=::1 listen_addr=::1";;
|
||||
esac
|
||||
fi
|
||||
|
||||
# fix client port
|
||||
if [ -n "$PXY_CMD" ]; then
|
||||
CLI_CMD=$( echo "$CLI_CMD" | sed s/+SRV_PORT/$PXY_PORT/g )
|
||||
@ -704,9 +717,6 @@ run_test() {
|
||||
CLI_CMD=$( echo "$CLI_CMD" | sed s/+SRV_PORT/$SRV_PORT/g )
|
||||
fi
|
||||
|
||||
# update DTLS variable
|
||||
detect_dtls "$SRV_CMD"
|
||||
|
||||
# prepend valgrind to our commands if active
|
||||
if [ "$MEMCHECK" -gt 0 ]; then
|
||||
if is_polar "$SRV_CMD"; then
|
||||
@ -723,19 +733,19 @@ run_test() {
|
||||
|
||||
# run the commands
|
||||
if [ -n "$PXY_CMD" ]; then
|
||||
echo "$PXY_CMD" > $PXY_OUT
|
||||
printf "# %s\n%s\n" "$NAME" "$PXY_CMD" > $PXY_OUT
|
||||
$PXY_CMD >> $PXY_OUT 2>&1 &
|
||||
PXY_PID=$!
|
||||
wait_proxy_start "$PXY_PORT" "$PXY_PID"
|
||||
fi
|
||||
|
||||
check_osrv_dtls
|
||||
echo "$SRV_CMD" > $SRV_OUT
|
||||
printf "# $NAME\n$SRV_CMD\n" > $SRV_OUT
|
||||
provide_input | $SRV_CMD >> $SRV_OUT 2>&1 &
|
||||
SRV_PID=$!
|
||||
wait_server_start "$SRV_PORT" "$SRV_PID"
|
||||
|
||||
echo "$CLI_CMD" > $CLI_OUT
|
||||
printf "# $NAME\n$CLI_CMD\n" > $CLI_OUT
|
||||
eval "$CLI_CMD" >> $CLI_OUT 2>&1 &
|
||||
wait_client_done
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user