Date: Fri, 29 Jan 2021 09:31:52 GMT From: Alex Richardson <arichardson@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: git: 892a05ee3a6a - main - Avoid double output in fenv_test Message-ID: <202101290931.10T9Vqeu010057@gitrepo.freebsd.org>
next in thread | raw e-mail | index | archive | help
The branch main has been updated by arichardson: URL: https://cgit.FreeBSD.org/src/commit/?id=892a05ee3a6abd8d84f46a1b895b1d2bf805d08a commit 892a05ee3a6abd8d84f46a1b895b1d2bf805d08a Author: Alex Richardson <arichardson@FreeBSD.org> AuthorDate: 2021-01-29 09:29:26 +0000 Commit: Alex Richardson <arichardson@FreeBSD.org> CommitDate: 2021-01-29 09:29:27 +0000 Avoid double output in fenv_test This tests fork()s, so if there is still data in the stdout buffer on fork it will print it again in the child process. This was happening in the CheriBSD CI and caused the test to complain about malformed TAP output. Reviewed By: ngie Differential Revision: https://reviews.freebsd.org/D28397 --- lib/msun/tests/fenv_test.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/msun/tests/fenv_test.c b/lib/msun/tests/fenv_test.c index 9b615b100e8a..62abfefb4a8a 100644 --- a/lib/msun/tests/fenv_test.c +++ b/lib/msun/tests/fenv_test.c @@ -539,6 +539,8 @@ test_feholdupdate(void) int main(void) { + /* Avoid double output after fork() */ + setvbuf(stdout, NULL, _IONBF, 0); printf("1..8\n"); init_exceptsets();
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202101290931.10T9Vqeu010057>