4 Commits

Author SHA1 Message Date
Andrew G. Morgan
025f28ca4f Avoid thread churn deadlock with PSX rewrite.
This bug, reported by David Runge, identifies another regression
vs. libpsx-2.71:

   https://bugzilla.kernel.org/show_bug.cgi?id=219687

A regression of the LWP threading support reintroduced an old bug
in the libpsx-2.72 rewrite, specifically this bug:

   https://github.com/golang/go/issues/42494

This present change includes x86_64, i386 and arm* (32-bit and 64-bit)
support. I've tested each of these with debian OSes, some running via QEMU.
Before releasing 2.74, I plan to extend the testing to all of the targets
supported by Debian (see https://wiki.debian.org/DebianInstaller/Qemu).

Signed-off-by: Andrew G. Morgan <morgan@kernel.org>
2025-02-01 08:49:27 -08:00
Andrew G. Morgan
12e163ac21 Rewrite libpsx to work with native linux threads.
This is more general than just working with -lpthread threads,
and addresses the following bug reports:

  https://bugzilla.kernel.org/show_bug.cgi?id=219174
  https://bugzilla.kernel.org/show_bug.cgi?id=218607
  https://bugzilla.kernel.org/show_bug.cgi?id=217476

Signed-off-by: Andrew G. Morgan <morgan@kernel.org>
2024-10-25 22:58:46 -07:00
Andrew G. Morgan
06ec53d0c9 Permit compilation with -std=c89.
Tested with

  make COPTS="-O2 -std=c89" clean all test sudotest

This addresses the issue reported by Byron Stanoszek:

  https://bugzilla.kernel.org/show_bug.cgi?id=213541

Signed-off-by: Andrew G. Morgan <morgan@kernel.org>
2021-06-21 17:46:43 -07:00
Andrew G. Morgan
481ca7b508 Demonstrate why libpsx is important for multithreaded C code.
I've heard a number of folk ask why one might need libpsx for anything
other than Go program linking, so this demonstrates the class of exploit
that is possible when libcap is linked with -lpthread and not -lpsx.

Signed-off-by: Andrew G. Morgan <morgan@kernel.org>
2020-10-24 21:00:59 -07:00