• Joel Sing's avatar
    archive/tar: fix race in TestNonSeekable · e3e1804e
    Joel Sing authored
    Reimplement the test based on code from adg@golang.org.
    
    The previous version has a race since the file is closed via defer
    rather than in the go routine. This meant that the file could be
    closed before the go routine has actually received io.EOF. It then
    receives EBADF and continues to do zero-byte writes to the pipe.
    
    This addresses an issue seen on FreeBSD and OpenBSD, where the test
    passes but exits with a SIGPIPE, resulting in a failure.
    
    R=golang-dev, adg
    CC=golang-dev
    https://golang.org/cl/5554083
    e3e1804e
Name
Last commit
Last update
..
buildscript Loading commit data...
cmd Loading commit data...
lib9 Loading commit data...
libbio Loading commit data...
libmach Loading commit data...
pkg Loading commit data...
Make.ccmd Loading commit data...
Make.clib Loading commit data...
Make.cmd Loading commit data...
Make.common Loading commit data...
Make.inc Loading commit data...
Make.pkg Loading commit data...
all-qemu.bash Loading commit data...
all.bash Loading commit data...
buildinfo.sh Loading commit data...
buildscript.sh Loading commit data...
clean.bash Loading commit data...
env.bash Loading commit data...
make.bash Loading commit data...
quietgcc.bash Loading commit data...
run.bash Loading commit data...
sudo.bash Loading commit data...
version.bash Loading commit data...