diff --git a/CHANGES b/CHANGES index 65adff1..38176ad 100644 --- a/CHANGES +++ b/CHANGES @@ -239,6 +239,9 @@ corrections: UDP-LISTEN failed with "...is not available". Thanks to Fred for reporting this problem + Address FD was not read from when used bidirectionally. Thanks to David + Halls for reporting this bug. + porting: Red Hat issue 1020203: configure checks fail with some compilers. Use case: clang diff --git a/test.sh b/test.sh index 30be1aa..2badac7 100755 --- a/test.sh +++ b/test.sh @@ -3968,7 +3968,7 @@ testchain "$N" "$TEST" "test|^test|test|^test|test|^test|test|^test|stdio" "pipe esac N=$((N+1)) -NAME=TOWLONGCHAINS +NAME=TWOLONGCHAINS case "$TESTS" in *%$N%*|*%functions%*|*%chain%*|*%$NAME%*) TEST="$NAME: four-tests+stdio vs. four-tests+pipe" @@ -12645,7 +12645,17 @@ esac N=$((N+1)) -echo "summary: $((N-1)) tests, $((numOK+numFAILED+numCANT)) selected; $numOK ok, $numFAIL failed, $numCANT could not be performed" +NAME=FD_BI_WRITE +case "$TESTS" in +*%$N%*|*%functions%*|*%chain%*|*%$NAME%*) +TEST="$NAME: FD address in birectional context is" +testecho "$N" "$TEST" "FD:0" "FD:1" "-T 2 $opts" "$val_t" +esac +N=$((N+1)) + + + +echo "summary: $((N-1)) tests, $((numOK+numFAIL+numCANT)) selected; $numOK ok, $numFAIL failed, $numCANT could not be performed" if [ "$numFAIL" -gt 0 ]; then echo "FAILED: $listFAIL" diff --git a/xio-fdnum.c b/xio-fdnum.c index 1b73892..8b43781 100644 --- a/xio-fdnum.c +++ b/xio-fdnum.c @@ -61,8 +61,8 @@ static int xioopen_fdnum(int argc, const char *argv[], struct opt *opts, } } else { if (XIOWITHWR(rw)) { + numrfd = numfd1; numwfd = numfd1; - numrfd = -1; } else { numrfd = numfd1; numwfd = -1;