summaryrefslogtreecommitdiff
path: root/src/regress/lib/libc/stdio_threading/flockfile/Makefile
diff options
context:
space:
mode:
authorguenther <>2026-01-19 23:01:00 +0000
committerguenther <>2026-01-19 23:01:00 +0000
commit28d8cf0bbfe2d8e27749a1453bd2771c8e41c31b (patch)
tree70a6f669625e0a3bd8d7ad550c55357341c846f0 /src/regress/lib/libc/stdio_threading/flockfile/Makefile
parent72cdd91797afb2b9796ee9f67324a53c5fc6effe (diff)
downloadopenbsd-28d8cf0bbfe2d8e27749a1453bd2771c8e41c31b.tar.gz
openbsd-28d8cf0bbfe2d8e27749a1453bd2771c8e41c31b.tar.bz2
openbsd-28d8cf0bbfe2d8e27749a1453bd2771c8e41c31b.zip
While almost all the libc locks are taken and released in the same
libc call, flockfile() and ftrylockfile() can be called when single-threaded and then--while 'holding' the lock--the process can create another thread, resulting in a broken state. Have the f{lock,trylock,unlock}file() APIs *always* do real locking so the exposed state is always consistent. ok dlg@
Diffstat (limited to 'src/regress/lib/libc/stdio_threading/flockfile/Makefile')
-rw-r--r--src/regress/lib/libc/stdio_threading/flockfile/Makefile6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/regress/lib/libc/stdio_threading/flockfile/Makefile b/src/regress/lib/libc/stdio_threading/flockfile/Makefile
new file mode 100644
index 0000000000..171ccc7ac7
--- /dev/null
+++ b/src/regress/lib/libc/stdio_threading/flockfile/Makefile
@@ -0,0 +1,6 @@
1TOPDIR=${.CURDIR}
2PROG=flockfile_test
3CFLAGS+=-I${TOPDIR}/../include/
4LDFLAGS+=-lpthread
5
6.include <bsd.regress.mk>