[gnutls-devel] gnutls28 3.2.6 - race condition in mini-handshake-timeout.c
Andreas Metzler
ametzler at bebt.de
Sun Nov 10 08:22:17 CET 2013
Good morning,
there is a race condition in mini-handshake-timeout.c which causes
spurious build failures. The issue appeared on the Debian
build-daemons
<https://buildd.debian.org/status/package.php?p=gnutls28&suite=experimental>.
It was diagnosed by Petr Salinger and Steven Chamberlain, Petr in
specific narrowd it down:
quote ------------------------------
| It also failed on mips, in the same test - mini-handshake-timeout.c
|
| It receives SIGPIPE during
| gnutls_bye(session, GNUTLS_SHUT_RDWR);
|
| There is a race window, which can be enlarged as shown bellow.
| After that it fails also under linux-i386 -> not kfreebsd specific.
|
| Petr
|
| --- tests/mini-handshake-timeout.c
| +++ tests/mini-handshake-timeout.c
| @@ -181,7 +181,10 @@
| while (ret < 0 && gnutls_error_is_fatal(ret) == 0);
|
| if (ret == 0)
| + {
| + sleep(1);
| gnutls_bye(session, GNUTLS_SHUT_RDWR);
| + }
| }
|
| gnutls_deinit (session);
unquote ----------------------------
See
<http://mid.gmane.org/alpine.LNX.2.00.1311091828310.32332%40contest.felk.cvut.cz>
and <http://mid.gmane.org/527E801B.9000101%40pyro.eu.org>.
cu Andreas
--
`What a good friend you are to him, Dr. Maturin. His other friends are
so grateful to you.'
`I sew his ears on from time to time, sure'
More information about the Gnutls-devel
mailing list