glibc/sysdeps
Florian Weimer e9fed2438a linux: Require /dev/shm as the shared memory file system
Previously, glibc would pick an arbitrary tmpfs file system from
/proc/mounts if /dev/shm was not available.  This could lead to
an unsuitable file system being picked for the backing storage for
shm_open, sem_open, and related functions.

This patch introduces a new function, __shm_get_name, which builds
the file name under the appropriate (now hard-coded) directory.  It is
called from the various shm_* and sem_* function.  Unlike the
SHM_GET_NAME macro it replaces, the callers handle the return values
and errno updates.  shm-directory.c is moved directly into the posix
subdirectory because it can be implemented directly using POSIX
functionality.  It resides in libc because it is needed by both
librt and nptl/htl.

In the sem_open implementation, tmpfname is initialized directly
from a string constant.  This happens to remove one alloca call.

Checked on x86_64-linux-gnu.
2021-02-08 14:10:42 -03:00
..
aarch64
alpha
arc
arm
csky
generic sysconf: Add _SC_MINSIGSTKSZ/_SC_SIGSTKSZ [BZ #20305] 2021-02-01 11:00:52 -08:00
gnu
hppa
htl linux: Require /dev/shm as the shared memory file system 2021-02-08 14:10:42 -03:00
hurd
i386 i686: Regenerate ULPs 2021-02-03 23:16:39 +05:30
ia64 Update ia64 libm-test-ulps 2021-01-28 14:05:15 -03:00
ieee754
m68k
mach hurd TIOCFLUSH: fix fixing argument 2021-02-01 20:01:34 +01:00
microblaze
mips
nios2
nptl linux: Require /dev/shm as the shared memory file system 2021-02-08 14:10:42 -03:00
posix linux: Require /dev/shm as the shared memory file system 2021-02-08 14:10:42 -03:00
powerpc
pthread linux: Require /dev/shm as the shared memory file system 2021-02-08 14:10:42 -03:00
riscv
s390
sh sh: Update libm-tests-ulps 2021-01-28 14:05:14 -03:00
sparc Update sparc libm-test-ulps 2021-01-28 14:05:14 -03:00
unix linux: Require /dev/shm as the shared memory file system 2021-02-08 14:10:42 -03:00
wordsize-32
wordsize-64
x86 x86: Add PTWRITE feature detection [BZ #27346] 2021-02-07 08:01:14 -08:00
x86_64 x86: Adding an upper bound for Enhanced REP MOVSB. 2021-02-02 12:42:15 +01:00