]> Savannah Git Hosting - gnulib.git/log
gnulib.git
8 months agotest-utime: port to noatime file systems
Paul Eggert [Fri, 9 Aug 2024 21:03:44 +0000 (14:03 -0700)]
test-utime: port to noatime file systems

Problem encountered on Ubuntu 24.04 zfs mounted noatime.
* tests/test-fdutimensat.c (main):
* tests/test-futimens.h (test_futimens):
* tests/test-lutimens.h (test_lutimens):
* tests/test-utime.c (test_utime):
* tests/test-utimens-common.h (checkable_atime): New function.
* tests/test-utimens.h (test_utimens):
* tests/test-utimensat.c (main):
Do not check atime on file systems mounted noatime.

8 months agoAvoid compiler warnings in some configure tests.
Bruno Haible [Wed, 7 Aug 2024 22:54:03 +0000 (00:54 +0200)]
Avoid compiler warnings in some configure tests.

* m4/pthread-rwlock.m4 (gl_PTHREAD_RWLOCK): Allocate more room for local
array 'name'.
* m4/pthread_mutex_timedlock.m4 (gl_FUNC_PTHREAD_MUTEX_TIMEDLOCK): Don't
pass a NULL pointer to pthread_mutex_timedlock.

8 months agopthread-rwlock: Fix default wait queue behaviour on glibc/Linux.
Bruno Haible [Wed, 7 Aug 2024 17:53:37 +0000 (19:53 +0200)]
pthread-rwlock: Fix default wait queue behaviour on glibc/Linux.

* lib/pthread.in.h: If REPLACE_PTHREAD_RWLOCK_INIT is 1 but
REPLACE_PTHREAD_RWLOCK_DESTROY is 0, override
PTHREAD_RWLOCK_INITIALIZER.
* lib/pthread-rwlock.c
(pthread_rwlockattr_init) [PTHREAD_RWLOCK_BAD_WAITQUEUE]: New function.
(pthread_rwlock_init) [PTHREAD_RWLOCK_BAD_WAITQUEUE]: New function.
* m4/pthread-rwlock.m4 (gl_PTHREAD_RWLOCK): Check for reasonable
pthread_rwlock wait queue handling. Set REPLACE_PTHREAD_RWLOCK_INIT and
REPLACE_PTHREAD_RWLOCKATTR_INIT and define PTHREAD_RWLOCK_BAD_WAITQUEUE
if not.
* modules/pthread-rwlock (configure.ac): Update
GL_COND_OBJ_PTHREAD_RWLOCK condition.
* doc/posix-functions/pthread_rwlock_rdlock.texi: Mark the glibc problem
as fixed.
* doc/posix-functions/pthread_rwlock_tryrdlock.texi: Likewise.
* doc/posix-functions/pthread_rwlock_timedrdlock.texi: Likewise.

8 months agofchmodat: Fix cross-compilation guess.
Bruno Haible [Wed, 7 Aug 2024 10:21:05 +0000 (12:21 +0200)]
fchmodat: Fix cross-compilation guess.

* m4/fchmodat.m4 (gl_FUNC_FCHMODAT): Tolerate Linux version number
in $host_os.

8 months agowindows-mutex, windows-timedmutex: Follow pthread_mutex_trylock spec.
Bruno Haible [Tue, 6 Aug 2024 13:14:25 +0000 (15:14 +0200)]
windows-mutex, windows-timedmutex: Follow pthread_mutex_trylock spec.

* lib/windows-mutex.h (glwthread_mutex_t): Add 'owner' field.
* lib/windows-mutex.c: Include <stdlib.h>.
(glwthread_mutex_lock): Set the 'owner' field after entering the
critical section.
(glwthread_mutex_trylock): Detect whether the lock was previously locked
by this thread. Set the 'owner' field after entering the critical
section.
(glwthread_mutex_unlock): Clear the 'owner' field before leaving the
critical section.
* lib/windows-timedmutex.h (glwthread_timedmutex_t): Add 'owner' field.
* lib/windows-timedmutex.c: (glwthread_timedmutex_lock): Set the 'owner'
field after entering the critical section.
(glwthread_timedmutex_trylock): Detect whether the lock was previously
locked by this thread. Set the 'owner' field after entering the critical
section.
(glwthread_timedmutex_unlock): Clear the 'owner' field before leaving
the critical section.

8 months agognulib-tool.py: Fix testdirs created with --without-tests.
Bruno Haible [Mon, 5 Aug 2024 18:24:44 +0000 (20:24 +0200)]
gnulib-tool.py: Fix testdirs created with --without-tests.

* pygnulib/GLTestDir.py (GLTestDir.execute): Don't assume that 'gltests'
is the last subdirectory with a configure.ac.

8 months agodfa-tests: Detect test-dfa-match-aux error.
Bernhard Voelker [Sun, 4 Aug 2024 16:14:32 +0000 (18:14 +0200)]
dfa-tests: Detect test-dfa-match-aux error.

* tests/test-dfa-invalid-merge.sh: Set fail=1 if test-dfa-match-aux fails.
Remove redundant 'returns_ 0'.

8 months agotest-framework-sh: Improve returns_ example.
Bernhard Voelker [Sun, 4 Aug 2024 16:12:16 +0000 (18:12 +0200)]
test-framework-sh: Improve returns_ example.

In the shell test framework, an error is either flagged by setting
the shell variable fail=1, or by invoking the fail_ function with an
error diagnostic.

* tests/init.sh (returns_): Change example code in the comment to
use '|| fail=1' properly.

8 months agovaszprintf-posix tests: Fix a gcc warning.
Bruno Haible [Tue, 30 Jul 2024 01:14:00 +0000 (03:14 +0200)]
vaszprintf-posix tests: Fix a gcc warning.

* tests/test-vaszprintf-posix.c (test_function): Remove an unused
variable.

8 months agoFix misspelling of __clang_major__.
Bruno Haible [Mon, 29 Jul 2024 19:59:44 +0000 (21:59 +0200)]
Fix misspelling of __clang_major__.

* lib/cdefs.h (__THROW, __THROWNL, __NTH, __NTHNL): Fix misspelled macro
name.
* m4/gnulib-common.m4 (gl_COMMON_BODY): Likewise.
* lib/malloc.in.h (_GL_ATTRIBUTE_NOTHROW): Likewise.
* lib/stddef.in.h (_GL_ATTRIBUTE_NOTHROW): Likewise.
* lib/stdio.in.h (_GL_ATTRIBUTE_NOTHROW): Likewise.
* lib/stdlib.in.h (_GL_ATTRIBUTE_NOTHROW): Likewise.
* lib/string.in.h (_GL_ATTRIBUTE_NOTHROW): Likewise.
* lib/sys_stat.in.h (_GL_ATTRIBUTE_NOTHROW): Likewise.
* lib/wchar.in.h (_GL_ATTRIBUTE_NOTHROW): Likewise.

8 months agochdir: Fix mistake in GNULIB_POSIXCHECK.
Bruno Haible [Mon, 29 Jul 2024 18:21:06 +0000 (20:21 +0200)]
chdir: Fix mistake in GNULIB_POSIXCHECK.

* lib/unistd.in.h: Don't attach the chdir warning to the 'chown'
function.

8 months agoatoll: Fix module dependencies.
Bruno Haible [Mon, 29 Jul 2024 18:17:06 +0000 (20:17 +0200)]
atoll: Fix module dependencies.

* modules/atoll (Depends-on): Add stdlib.

8 months agognulib-tool.py: Fix an exception message.
Bruno Haible [Sun, 28 Jul 2024 21:38:45 +0000 (23:38 +0200)]
gnulib-tool.py: Fix an exception message.

* pygnulib/GLModuleSystem.py (GLModuleSystem.find): Raise error 23,
not 3.
* pygnulib/GLError.py: Provide an error message for error 23.
* pygnulib/main.py: Likewise.

8 months agoautoupdate
Paul Eggert [Sun, 28 Jul 2024 20:07:43 +0000 (13:07 -0700)]
autoupdate

8 months agosys_time, sys_types: Remove sys directory at 'make mostlyclean'.
Collin Funk [Sat, 27 Jul 2024 01:37:09 +0000 (18:37 -0700)]
sys_time, sys_types: Remove sys directory at 'make mostlyclean'.

* modules/sys_time (Makefile.am): Add sys to MOSTLYCLEANDIRS.
* modules/sys_types (Makefile.am): Likewise.

8 months agoAvoid false select_used_without_requesting_gnulib_module_select.
Bruno Haible [Wed, 24 Jul 2024 23:29:22 +0000 (01:29 +0200)]
Avoid false select_used_without_requesting_gnulib_module_select.

* modules/select (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/sys_select.in.h (select): Don't define to
select_used_without_requesting_gnulib_module_select if the gnulib module
'select' is in use under the same configure.ac.

8 months agoAvoid false shutdown_used_without_requesting_gnulib_module_shutdown.
Bruno Haible [Wed, 24 Jul 2024 23:27:32 +0000 (01:27 +0200)]
Avoid false shutdown_used_without_requesting_gnulib_module_shutdown.

* modules/shutdown (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/sys_socket.in.h (shutdown): Don't define to
shutdown_used_without_requesting_gnulib_module_shutdown if the gnulib
module 'shutdown' is in use under the same configure.ac.

8 months agoAvoid false setsockopt_used_without_requesting_gnulib_module_setsockopt.
Bruno Haible [Wed, 24 Jul 2024 23:23:52 +0000 (01:23 +0200)]
Avoid false setsockopt_used_without_requesting_gnulib_module_setsockopt.

* modules/setsockopt (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/sys_socket.in.h (setsockopt): Don't define to
setsockopt_used_without_requesting_gnulib_module_setsockopt if the
gnulib module 'setsockopt' is in use under the same configure.ac.

8 months agoAvoid false sendto_used_without_requesting_gnulib_module_sendto.
Bruno Haible [Wed, 24 Jul 2024 23:21:45 +0000 (01:21 +0200)]
Avoid false sendto_used_without_requesting_gnulib_module_sendto.

* modules/sendto (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/sys_socket.in.h (sendto): Don't define to
sendto_used_without_requesting_gnulib_module_sendto if the gnulib module
'sendto' is in use under the same configure.ac.

8 months agoAvoid false recvfrom_used_without_requesting_gnulib_module_recvfrom.
Bruno Haible [Wed, 24 Jul 2024 23:19:20 +0000 (01:19 +0200)]
Avoid false recvfrom_used_without_requesting_gnulib_module_recvfrom.

* modules/recvfrom (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/sys_socket.in.h (recvfrom): Don't define to
recvfrom_used_without_requesting_gnulib_module_recvfrom if the gnulib
module 'recvfrom' is in use under the same configure.ac.

8 months agoAvoid false send_used_without_requesting_gnulib_module_send.
Bruno Haible [Wed, 24 Jul 2024 23:17:33 +0000 (01:17 +0200)]
Avoid false send_used_without_requesting_gnulib_module_send.

* modules/send (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/sys_socket.in.h (send): Don't define to
send_used_without_requesting_gnulib_module_send if the gnulib module
'send' is in use under the same configure.ac.

8 months agoAvoid false recv_used_without_requesting_gnulib_module_recv.
Bruno Haible [Wed, 24 Jul 2024 23:16:05 +0000 (01:16 +0200)]
Avoid false recv_used_without_requesting_gnulib_module_recv.

* modules/recv (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/sys_socket.in.h (recv): Don't define to
recv_used_without_requesting_gnulib_module_recv if the gnulib module
'recv' is in use under the same configure.ac.

8 months agoAvoid false listen_used_without_requesting_gnulib_module_listen.
Bruno Haible [Wed, 24 Jul 2024 23:14:25 +0000 (01:14 +0200)]
Avoid false listen_used_without_requesting_gnulib_module_listen.

* modules/listen (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/sys_socket.in.h (listen): Don't define to
listen_used_without_requesting_gnulib_module_listen if the gnulib module
'listen' is in use under the same configure.ac.

8 months agoAvoid false getsockopt_used_without_requesting_gnulib_module_getsockopt.
Bruno Haible [Wed, 24 Jul 2024 23:12:43 +0000 (01:12 +0200)]
Avoid false getsockopt_used_without_requesting_gnulib_module_getsockopt.

* modules/getsockopt (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/sys_socket.in.h (getsockopt): Don't define to
getsockopt_used_without_requesting_gnulib_module_getsockopt if the
gnulib module 'getsockopt' is in use under the same configure.ac.

8 months agoAvoid false getsockname_used_without_requesting_gnulib_module_getsockname.
Bruno Haible [Wed, 24 Jul 2024 22:53:05 +0000 (00:53 +0200)]
Avoid false getsockname_used_without_requesting_gnulib_module_getsockname.

* modules/getsockname (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/sys_socket.in.h (getsockname): Don't define to
getsockname_used_without_requesting_gnulib_module_getsockname if the
gnulib module 'getsockname' is in use under the same configure.ac.

8 months agoAvoid false getpeername_used_without_requesting_gnulib_module_getpeername.
Bruno Haible [Wed, 24 Jul 2024 22:51:27 +0000 (00:51 +0200)]
Avoid false getpeername_used_without_requesting_gnulib_module_getpeername.

* modules/getpeername (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/sys_socket.in.h (getpeername): Don't define to
getpeername_used_without_requesting_gnulib_module_getpeername if the
gnulib module 'getpeername' is in use under the same configure.ac.

8 months agoAvoid false bind_used_without_requesting_gnulib_module_bind.
Bruno Haible [Wed, 24 Jul 2024 22:49:21 +0000 (00:49 +0200)]
Avoid false bind_used_without_requesting_gnulib_module_bind.

* modules/bind (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/sys_socket.in.h (bind): Don't define to
bind_used_without_requesting_gnulib_module_bind if the gnulib module
'bind' is in use under the same configure.ac.

8 months agoAvoid false accept_used_without_requesting_gnulib_module_accept.
Bruno Haible [Wed, 24 Jul 2024 22:47:45 +0000 (00:47 +0200)]
Avoid false accept_used_without_requesting_gnulib_module_accept.

* modules/accept (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/sys_socket.in.h (accept): Don't define to
accept_used_without_requesting_gnulib_module_accept if the gnulib module
'accept' is in use under the same configure.ac.

8 months agoAvoid false socket_used_without_requesting_gnulib_module_connect.
Bruno Haible [Wed, 24 Jul 2024 22:41:00 +0000 (00:41 +0200)]
Avoid false socket_used_without_requesting_gnulib_module_connect.

* modules/connect (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/sys_socket.in.h (connect): Don't define to
socket_used_without_requesting_gnulib_module_connect if the gnulib
module 'connect' is in use under the same configure.ac. Fix typo.

8 months agoAvoid false socket_used_without_requesting_gnulib_module_socket.
Bruno Haible [Wed, 24 Jul 2024 22:38:08 +0000 (00:38 +0200)]
Avoid false socket_used_without_requesting_gnulib_module_socket.

* modules/socket (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/sys_socket.in.h (socket): Don't define to
socket_used_without_requesting_gnulib_module_socket if the gnulib module
'socket' is in use under the same configure.ac.

8 months agoAvoid false lstat_used_without_requesting_gnulib_module_lstat.
Bruno Haible [Wed, 24 Jul 2024 22:36:01 +0000 (00:36 +0200)]
Avoid false lstat_used_without_requesting_gnulib_module_lstat.

* modules/lstat (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/sys_stat.in.h (lstat): Don't define to
lstat_used_without_requesting_gnulib_module_lstat if the gnulib module
'lstat' is in use under the same configure.ac.

8 months agoAvoid false fstatat_used_without_requesting_gnulib_module_fstatat.
Bruno Haible [Wed, 24 Jul 2024 22:34:09 +0000 (00:34 +0200)]
Avoid false fstatat_used_without_requesting_gnulib_module_fstatat.

* modules/fstatat (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/sys_stat.in.h (fstatat): Don't define to
fstatat_used_without_requesting_gnulib_module_fstatat if the gnulib
module 'fstatat' is in use under the same configure.ac.

8 months agoAvoid false fstat_used_without_requesting_gnulib_module_fstat.
Bruno Haible [Wed, 24 Jul 2024 22:32:26 +0000 (00:32 +0200)]
Avoid false fstat_used_without_requesting_gnulib_module_fstat.

* modules/fstat (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/sys_stat.in.h (fstat): Don't define to
fstat_used_without_requesting_gnulib_module_fstat if the gnulib module
'fstat' is in use under the same configure.ac.

8 months agoAvoid false stat_used_without_requesting_gnulib_module_stat.
Bruno Haible [Wed, 24 Jul 2024 22:30:26 +0000 (00:30 +0200)]
Avoid false stat_used_without_requesting_gnulib_module_stat.

* modules/stat (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/sys_stat.in.h (stat): Don't define to
stat_used_without_requesting_gnulib_module_stat if the gnulib module
'stat' is in use under the same configure.ac.

8 months agoAvoid false ioctl_used_without_requesting_gnulib_module_ioctl.
Bruno Haible [Wed, 24 Jul 2024 21:59:15 +0000 (23:59 +0200)]
Avoid false ioctl_used_without_requesting_gnulib_module_ioctl.

* modules/ioctl (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/sys_ioctl.in.h (ioctl): Don't define to
ioctl_used_without_requesting_gnulib_module_ioctl if the gnulib module
'ioctl' is in use under the same configure.ac.

8 months agoAvoid false localeconv_used_without_requesting_gnulib_module_localeconv.
Bruno Haible [Wed, 24 Jul 2024 21:56:33 +0000 (23:56 +0200)]
Avoid false localeconv_used_without_requesting_gnulib_module_localeconv.

* modules/localeconv (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/locale.in.h (localeconv): Don't define to
localeconv_used_without_requesting_gnulib_module_localeconv if the
gnulib module 'localeconv' is in use under the same configure.ac.

8 months agoAvoid false gethostname_used_without_requesting_gnulib_module_gethostname.
Bruno Haible [Wed, 24 Jul 2024 21:53:53 +0000 (23:53 +0200)]
Avoid false gethostname_used_without_requesting_gnulib_module_gethostname.

* modules/gethostname (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/unistd.in.h (gethostname): Don't define to
gethostname_used_without_requesting_gnulib_module_gethostname if the
gnulib module 'gethostname' is in use under the same configure.ac.

8 months agoAvoid false error close_used_without_requesting_gnulib_module_close.
Bruno Haible [Wed, 24 Jul 2024 21:35:53 +0000 (23:35 +0200)]
Avoid false error close_used_without_requesting_gnulib_module_close.

Reported by Frédéric at <https://savannah.gnu.org/bugs/?65958>.

* modules/close (configure.ac): Invoke gl_MODULE_INDICATOR.
* lib/unistd.in.h (close): Don't define to
close_used_without_requesting_gnulib_module_close if the gnulib module
'close' is in use under the same configure.ac.

8 months agogetopt-posix, getopt-gnu tests: Avoid test failure on mingw.
Bruno Haible [Wed, 24 Jul 2024 00:02:45 +0000 (02:02 +0200)]
getopt-posix, getopt-gnu tests: Avoid test failure on mingw.

* tests/test-getopt.h (test_getopt): Don't special-case mingw.

8 months agostrtod: Revisit underflow behaviour.
Bruno Haible [Tue, 23 Jul 2024 10:40:37 +0000 (12:40 +0200)]
strtod: Revisit underflow behaviour.

* doc/posix-functions/strtod.texi: Mention the macOS bug. Mention that
gradual underflow does not count as an error on Cygwin 2.9 and MSVC.
* m4/strtod.m4 (gl_FUNC_STRTOD): Update comment.
* tests/test-strtod.h (test_function): Add a gradual underflow test.
Check the sign in case of flush-to-zero underflow.

8 months agostrtof: Revisit underflow behaviour.
Bruno Haible [Tue, 23 Jul 2024 10:40:33 +0000 (12:40 +0200)]
strtof: Revisit underflow behaviour.

* doc/posix-functions/strtof.texi: Mention the macOS bug. Mention the
mingw overflow bug. Mention the underflow bugs on Cygwin 2.9 and mingw.
Mention that gradual underflow does not count as an error on Cygwin 2.9,
mingw, MSVC.
* m4/strtof.m4 (gl_FUNC_STRTOF): Test against the mingw overflow bug.
* tests/test-strtof.h (test_function): Add a gradual underflow test.
Check the sign in case of flush-to-zero underflow.

8 months agostrtof, strtod, strtold: Fix underflow behaviour of system function.
Bruno Haible [Tue, 23 Jul 2024 10:40:19 +0000 (12:40 +0200)]
strtof, strtod, strtold: Fix underflow behaviour of system function.

* m4/strtof.m4 (gl_FUNC_STRTOF): Test for strtof's behaviour upon
underflow. Conditionally define STRTOF_HAS_UNDERFLOW_BUG,
STRTOF_HAS_GRADUAL_UNDERFLOW_PROBLEM.
* m4/strtod.m4 (gl_FUNC_STRTOD): Test for strtod's behaviour upon
underflow. Conditionally define STRTOD_HAS_UNDERFLOW_BUG,
STRTOD_HAS_GRADUAL_UNDERFLOW_PROBLEM.
* m4/strtold.m4 (gl_FUNC_STRTOLD): Test for strtold's behaviour upon
gradual underflow. Conditionally define
STRTOLD_HAS_GRADUAL_UNDERFLOW_PROBLEM.
* lib/strtod.c (HAVE_UNDERLYING_STRTOD): Test STRTOF_HAS_UNDERFLOW_BUG,
STRTOD_HAS_UNDERFLOW_BUG.
(HAS_GRADUAL_UNDERFLOW_PROBLEM): New macro.
(SET_ERRNO_UPON_GRADUAL_UNDERFLOW): New macro.
(STRTOD): Use it.

8 months agostrtof: Use the system's strtof() if available.
Bruno Haible [Tue, 23 Jul 2024 10:40:15 +0000 (12:40 +0200)]
strtof: Use the system's strtof() if available.

* m4/strtof.m4 (gl_FUNC_STRTOF): Define HAVE_STRTOF if strtof exists.

8 months agostrtof, strtod, strtold: Set errno upon gradual underflow.
Bruno Haible [Tue, 23 Jul 2024 08:39:28 +0000 (10:39 +0200)]
strtof, strtod, strtold: Set errno upon gradual underflow.

* lib/strtod.c (scale_radix_exp): If the result is a denormalized
number, set errno to ERANGE.

8 months agobootstrap: Avoid failure when gnulib-tool removed gettext.m4.
Bruno Haible [Sun, 21 Jul 2024 12:02:58 +0000 (14:02 +0200)]
bootstrap: Avoid failure when gnulib-tool removed gettext.m4.

* top/bootstrap-funclib.sh (autogen): When gnulib-tool has removed
gettext.m4 but the package needs gettext.m4, repeat the autopoint and
gnulib-tool invocations.
* build-aux/bootstrap: Regenerated.

9 months agogetpayload*: Do use glibc's implementation when it works.
Bruno Haible [Sat, 20 Jul 2024 14:38:11 +0000 (16:38 +0200)]
getpayload*: Do use glibc's implementation when it works.

Reported by Andreas K. Huettel <dilfridge@gentoo.org> in
<https://lists.gnu.org/archive/html/bug-gnulib/2024-07/msg00206.html>.

* m4/getpayload.m4 (gl_FUNC_GETPAYLOADF, gl_FUNC_GETPAYLOAD,
gl_FUNC_GETPAYLOADL): Link the test program with -lm if needed.

9 months agostrnlen: port to Android 5.0 (API 21)
Paul Eggert [Mon, 15 Jul 2024 21:14:55 +0000 (14:14 -0700)]
strnlen: port to Android 5.0 (API 21)

This is needed for GNU Emacs, which attempts to port to these
old Android versions.
* m4/strnlen.m4 (AC_FUNC_STRNLEN): Replace if Autoconf 2.72 or
earlier, with code that detects the Android problem with strnlen.
This version works around some further bugs in the test, notably,
misplaced 'volatile' and need for volatile in the AIX 4.3 bug
check too.

9 months agomanywarnings: Don't enable -Wsystem-headers.
Bruno Haible [Mon, 15 Jul 2024 21:02:58 +0000 (23:02 +0200)]
manywarnings: Don't enable -Wsystem-headers.

* build-aux/gcc-warning.spec: Add -Wsystem-headers.
* build-aux/g++-warning.spec: Likewise.
* m4/manywarnings.m4 (gl_MANYWARN_ALL_GCC(C)): Don't enable
-Wsystem-headers.
* m4/manywarnings-c++.m4 (gl_MANYWARN_ALL_GCC_CXX_IMPL): Likewise.

9 months agoqcopy-acl: Fix copying of ACLs on CentOS 7 (regression 2023-01-12).
Bruno Haible [Mon, 15 Jul 2024 12:48:41 +0000 (14:48 +0200)]
qcopy-acl: Fix copying of ACLs on CentOS 7 (regression 2023-01-12).

* lib/qcopy-acl.c: Include <string.h>, <linux/xattr.h>.
(XATTR_NAME_NFSV4_ACL, XATTR_NAME_POSIX_ACL_ACCESS,
XATTR_NAME_POSIX_ACL_DEFAULT): New macros, from file-has-acl.c.
(is_attr_permissions): Test for these names explicitly.
* m4/acl.m4 (gl_QCOPY_ACL): New macro.
* modules/qcopy-acl (Files): Add m4/acl.m4.
(configure.ac): Invoke gl_QCOPY_ACL.

9 months agostdlib: Avoid syntax errors in libstdc++ header files.
Bruno Haible [Sun, 14 Jul 2024 18:45:46 +0000 (20:45 +0200)]
stdlib: Avoid syntax errors in libstdc++ header files.

* lib/stdlib.in.h: Include <string> before strtol, strtoll, strtoul, or
strtoull gets defined as a macro.

9 months agoActivate strtold workarounds.
Bruno Haible [Sun, 14 Jul 2024 16:39:29 +0000 (18:39 +0200)]
Activate strtold workarounds.

* modules/c-strtold-tests (Depends-on): Add strtold.
* modules/ldtoastr (Depends-on): Add strtold.

9 months agostrtold: Work around major mingw bugs.
Bruno Haible [Sun, 14 Jul 2024 16:38:16 +0000 (18:38 +0200)]
strtold: Work around major mingw bugs.

* lib/strtod.c (HAVE_UNDERLYING_STRTOD) [USE_LONG_DOUBLE]: Set to 0 on
mingw versions before 10.0.
* doc/posix-functions/strtold.texi: Mention the mingw bugs.

9 months agostdlib: Support use of clang++ on Ubuntu.
Bruno Haible [Sat, 13 Jul 2024 22:53:57 +0000 (00:53 +0200)]
stdlib: Support use of clang++ on Ubuntu.

* lib/stdlib.in.h: Ignore __need_system_stdlib_h when GCC's
c++/11/stdlib.h is being included or has been included.

9 months agotimespec-sub: Fix compilation error on clang.
Pip Cet [Wed, 10 Jul 2024 15:56:34 +0000 (15:56 +0000)]
timespec-sub: Fix compilation error on clang.

Reported by Gerd Möllmann <gerd.moellmann@gmail.com> at
<https://debbugs.gnu.org/cgi/bugreport.cgi?bug=72036>.

* lib/timespec-sub.c (timespec_sub): Use 'int' as type of variable.
Copyright-paperwork-exempt: Yes

9 months agopthread-cond: Fix compilation error on native Windows.
Bruno Haible [Sun, 7 Jul 2024 00:53:37 +0000 (02:53 +0200)]
pthread-cond: Fix compilation error on native Windows.

* lib/pthread-cond.c: Include windows-cond.h, not windows-thread.h.

9 months agoAvoid some possibly wrong configure test results.
Bruno Haible [Mon, 1 Jul 2024 15:33:17 +0000 (17:33 +0200)]
Avoid some possibly wrong configure test results.

Reported by Arsen Arsenović <arsen@gentoo.org> in
<https://lists.gnu.org/archive/html/bug-gnulib/2024-07/msg00000.html>.

* m4/printf.m4 (gl_PRINTF_DIRECTIVE_N): Include necessary header file
for _exit().
(gl_SNPRINTF_DIRECTIVE_N): Likewise.
* m4/memmem.m4 (gl_FUNC_MEMMEM): Update comment.
* m4/sleep.m4 (gl_FUNC_SLEEP): Likewise.
* m4/strcasestr.m4 (gl_FUNC_STRCASESTR): Likewise.
* m4/strstr.m4 (gl_FUNC_STRSTR): Likewise.
* m4/wcsstr.m4 (gl_FUNC_WCSSTR): Likewise.

10 months agodoc: Remove references to POSIX 202x.
Collin Funk [Sun, 30 Jun 2024 23:29:01 +0000 (16:29 -0700)]
doc: Remove references to POSIX 202x.

* doc/posix-functions/encrypt.texi: Document as obsolete in
POSIX.1-2024.
* doc/posix-functions/inet_addr.texi: Likewise.
* doc/posix-functions/inet_ntoa.texi: Likewise.
* doc/posix-functions/setkey.texi: Likewise.
* doc/posix-functions/ftw.texi: Document as removed in POSIX.1-2024.
Link the POSIX.1-2017 specification.
* doc/posix-functions/getitimer.texi: Likewise.
* doc/posix-functions/setitimer.texi: Likewise.
* doc/posix-functions/toascii.texi: Likewise.

10 months ago*printf* tests: Remove unused includes.
Bruno Haible [Sun, 30 Jun 2024 21:30:32 +0000 (23:30 +0200)]
*printf* tests: Remove unused includes.

* tests/test-fprintf-gnu.c: Don't include <stdarg.h>.
* tests/test-fprintf-posix.c: Likewise.
* tests/test-szprintf-gnu.c: Likewise.
* tests/test-szprintf-posix.c: Likewise.
* tests/test-xfprintf-posix.c: Likewise.

10 months agovprintf-posix tests: Fix test title.
Bruno Haible [Sun, 30 Jun 2024 21:26:35 +0000 (23:26 +0200)]
vprintf-posix tests: Fix test title.

* tests/test-vprintf-posix.c: Fix title.

10 months agozprintf-gnu: Add tests.
Bruno Haible [Sun, 30 Jun 2024 21:10:41 +0000 (23:10 +0200)]
zprintf-gnu: Add tests.

* tests/test-zprintf-gnu.c: New file, based on tests/test-printf-gnu.c.
* tests/test-zprintf-gnu.sh: New file, based on
tests/test-printf-gnu.sh.
* modules/zprintf-gnu-tests: New file.

10 months agozprintf-gnu: New module.
Bruno Haible [Sun, 30 Jun 2024 21:06:12 +0000 (23:06 +0200)]
zprintf-gnu: New module.

* modules/zprintf-gnu: New file.

10 months agovzprintf-gnu: Add tests.
Bruno Haible [Sun, 30 Jun 2024 21:04:37 +0000 (23:04 +0200)]
vzprintf-gnu: Add tests.

* tests/test-printf-gnu.h (test_function): Use RETTYPE instead of 'int'.
* tests/test-printf-gnu.c (RETTYPE): New macro.
* tests/test-vprintf-gnu.c (RETTYPE): New macro.
* tests/test-vzprintf-gnu.c: New file, based on
tests/test-vprintf-gnu.c.
* tests/test-vzprintf-gnu.sh: New file, based on
tests/test-vprintf-gnu.sh.
* modules/vzprintf-gnu-tests: New file.

10 months agovzprintf-gnu: New module.
Bruno Haible [Sun, 30 Jun 2024 20:57:50 +0000 (22:57 +0200)]
vzprintf-gnu: New module.

* modules/vzprintf-gnu: New file.

10 months agofzprintf-gnu: Add tests.
Bruno Haible [Sun, 30 Jun 2024 20:56:15 +0000 (22:56 +0200)]
fzprintf-gnu: Add tests.

* tests/test-fzprintf-gnu.c: New file, based on
tests/test-fprintf-gnu.c.
* tests/test-fzprintf-gnu.sh: New file, based on
tests/test-fprintf-gnu.sh.
* modules/fzprintf-gnu-tests: New file.

10 months agofzprintf-gnu: New module.
Bruno Haible [Sun, 30 Jun 2024 20:49:52 +0000 (22:49 +0200)]
fzprintf-gnu: New module.

* modules/fzprintf-gnu: New file.

10 months agovfzprintf-gnu: Add tests.
Bruno Haible [Sun, 30 Jun 2024 20:42:20 +0000 (22:42 +0200)]
vfzprintf-gnu: Add tests.

* tests/test-vfzprintf-gnu.c: New file, based on
tests/test-vfprintf-gnu.c.
* tests/test-vfzprintf-gnu.sh: New file, based on
tests/test-vfprintf-gnu.sh.
* tests/test-fprintf-gnu.h: Update title.
* modules/vfzprintf-gnu-tests: New file.

10 months agovfzprintf-gnu: New module.
Bruno Haible [Sun, 30 Jun 2024 20:36:22 +0000 (22:36 +0200)]
vfzprintf-gnu: New module.

* modules/vfzprintf-gnu: New file.

10 months agozprintf-posix: Add tests.
Bruno Haible [Sun, 30 Jun 2024 20:23:45 +0000 (22:23 +0200)]
zprintf-posix: Add tests.

* tests/test-zprintf-posix.c: New file, based on
tests/test-printf-posix.c.
* tests/test-zprintf-posix.sh: New file, based on
tests/test-printf-posix.sh.
* modules/zprintf-posix-tests: New file.

10 months agozprintf-posix: New module.
Bruno Haible [Sun, 30 Jun 2024 20:17:44 +0000 (22:17 +0200)]
zprintf-posix: New module.

* modules/zprintf-posix: New file.

10 months agovzprintf-posix: Add tests.
Bruno Haible [Sun, 30 Jun 2024 20:12:41 +0000 (22:12 +0200)]
vzprintf-posix: Add tests.

* tests/test-printf-posix.h (test_function): Use RETTYPE instead of
'int'.
* tests/test-printf-posix.c (RETTYPE): New macro.
* tests/test-vprintf-posix.c (RETTYPE): New macro.
* tests/test-xprintf-posix.c (RETTYPE): New macro.
* tests/test-vzprintf-posix.c: New file, based on
tests/test-vprintf-posix.c.
* tests/test-vzprintf-posix.sh: New file, based on
tests/test-vprintf-posix.sh.
* modules/vzprintf-posix-tests: New file.

10 months agovzprintf-posix: New module.
Bruno Haible [Sun, 30 Jun 2024 19:57:26 +0000 (21:57 +0200)]
vzprintf-posix: New module.

* modules/vzprintf-posix: New file.

10 months agofzprintf-posix: Add tests.
Bruno Haible [Sun, 30 Jun 2024 19:55:13 +0000 (21:55 +0200)]
fzprintf-posix: Add tests.

* tests/test-fzprintf-posix.c: New file, based on
tests/test-fprintf-posix.c.
* tests/test-fzprintf-posix.sh: New file, based on
tests/test-fprintf-posix.sh.
* modules/fzprintf-posix-tests: New file.

10 months agofzprintf-posix: New module.
Bruno Haible [Sun, 30 Jun 2024 19:18:35 +0000 (21:18 +0200)]
fzprintf-posix: New module.

* modules/fzprintf-posix: New file.

10 months agovfzprintf-posix: Add tests.
Bruno Haible [Sun, 30 Jun 2024 19:17:03 +0000 (21:17 +0200)]
vfzprintf-posix: Add tests.

* tests/test-vfzprintf-posix.c: New file, based on
tests/test-vfprintf-posix.c.
* tests/test-vfzprintf-posix.sh: New file, based on
tests/test-vfprintf-posix.sh.
* tests/test-fprintf-posix.h: Update title.
* modules/vfzprintf-posix-tests: New file.

10 months agovfzprintf-posix: New module.
Bruno Haible [Sun, 30 Jun 2024 19:07:12 +0000 (21:07 +0200)]
vfzprintf-posix: New module.

* modules/vfzprintf-posix: New file.

10 months agoprintf-posix: Document properly.
Bruno Haible [Sun, 30 Jun 2024 19:00:47 +0000 (21:00 +0200)]
printf-posix: Document properly.

* lib/stdio.in.h (printf): Add specification.
* lib/vprintf.c (printf): Remove specification.

10 months agozprintf: New module.
Bruno Haible [Sun, 30 Jun 2024 18:58:29 +0000 (20:58 +0200)]
zprintf: New module.

* lib/stdio.in.h (zprintf): New declaration.
* lib/zprintf.c: New file, based on lib/vzprintf.c.
* m4/stdio_h.m4 (gl_STDIO_H_REQUIRE_DEFAULTS): Initialize
GNULIB_ZPRINTF.
* modules/stdio (Makefile.am): Substitute GNULIB_ZPRINTF.
* modules/zprintf: New file.

10 months agovprintf-posix: Document properly.
Bruno Haible [Sun, 30 Jun 2024 18:15:58 +0000 (20:15 +0200)]
vprintf-posix: Document properly.

* lib/stdio.in.h (vprintf): Add specification.
* lib/vprintf.c (vprintf): Remove specification.

10 months agovzprintf: New module.
Bruno Haible [Sun, 30 Jun 2024 18:00:58 +0000 (20:00 +0200)]
vzprintf: New module.

* lib/stdio.in.h (vzprintf): New declaration.
* lib/vzprintf.c: New file, based on lib/vprintf.c.
* m4/stdio_h.m4 (gl_STDIO_H_REQUIRE_DEFAULTS): Initialize
GNULIB_VZPRINTF.
* modules/stdio (Makefile.am): Substitute GNULIB_VZPRINTF.
* modules/vzprintf: New file.

10 months agofprintf-posix: Use vfzprintf.
Bruno Haible [Sun, 30 Jun 2024 17:47:26 +0000 (19:47 +0200)]
fprintf-posix: Use vfzprintf.

* lib/stdio.in.h (fprintf): Add specification.
* lib/fprintf.c: Don't include <stdlib.h>, vasnprintf.h.
Include intprops.h.
(fprintf): Implement based on vfzprintf.
* modules/fprintf-posix (Depends-on): Add vfzprintf, intprops. Remove
vasnprintf, free-posix.

10 months agofzprintf: New module.
Bruno Haible [Sun, 30 Jun 2024 17:40:35 +0000 (19:40 +0200)]
fzprintf: New module.

* lib/stdio.in.h (fzprintf): New declaration.
* lib/fzprintf.c: New file, based on lib/vfzprintf.c.
* m4/stdio_h.m4 (gl_STDIO_H_REQUIRE_DEFAULTS): Initialize
GNULIB_FZPRINTF.
* modules/stdio (Makefile.am): Substitute GNULIB_FZPRINTF.
* modules/fzprintf: New file.

10 months agovfprintf-posix: Use vfzprintf.
Bruno Haible [Sun, 30 Jun 2024 16:45:25 +0000 (18:45 +0200)]
vfprintf-posix: Use vfzprintf.

* lib/stdio.in.h (vfprintf): Add specification.
* lib/vfprintf.c: Don't include <stdlib.h>, vasnprintf.h.
Include intprops.h.
(vfprintf): Implement based on vfzprintf.
* modules/vfprintf-posix (Depends-on): Add vfzprintf, intprops. Remove
vasnprintf, free-posix.

10 months agovfzprintf: New module.
Bruno Haible [Sun, 30 Jun 2024 16:31:56 +0000 (18:31 +0200)]
vfzprintf: New module.

* lib/stdio.in.h (vfzprintf): New declaration.
* lib/vfzprintf.c: New file, based on lib/vfprintf.c and
lib/vdzprintf.c.
* m4/stdio_h.m4 (gl_STDIO_H_REQUIRE_DEFAULTS): Initialize
GNULIB_VFZPRINTF.
* modules/stdio (Makefile.am): Substitute GNULIB_VFZPRINTF.
* modules/vfzprintf: New file.

10 months agodzprintf-gnu: Add tests.
Bruno Haible [Sun, 30 Jun 2024 15:43:45 +0000 (17:43 +0200)]
dzprintf-gnu: Add tests.

* tests/test-dprintf-gnu.h: New file, extracted from
tests/test-dprintf-gnu.c.
* tests/test-dprintf-gnu.c: Include it.
(test_function): Remove function.
* modules/dprintf-gnu-tests (Files): Add it.
* tests/test-dzprintf-gnu.c: New file, based on
tests/test-dprintf-gnu.c.
* tests/test-dzprintf-gnu.sh: New file, based on
tests/test-dprintf-gnu.sh.
* modules/dzprintf-gnu-tests: New file.

10 months agodzprintf-gnu: New module.
Bruno Haible [Sun, 30 Jun 2024 15:32:14 +0000 (17:32 +0200)]
dzprintf-gnu: New module.

* modules/dzprintf-gnu: New file.

10 months agovdzprintf-gnu: Add tests.
Bruno Haible [Sun, 30 Jun 2024 15:29:44 +0000 (17:29 +0200)]
vdzprintf-gnu: Add tests.

* tests/test-fprintf-gnu.h (test_function): Use RETTYPE instead of
'int'.
* tests/test-fprintf-gnu.c (RETTYPE): New macro.
* tests/test-vdprintf-gnu.c (RETTYPE): New macro.
* tests/test-vfprintf-gnu.c (RETTYPE): New macro.
* tests/test-vdzprintf-gnu.c: New file, based on
tests/test-vdzprintf-posix.c.
* tests/test-vdzprintf-gnu.sh: New file, based on
tests/test-vdzprintf-posix.sh.
* modules/vdzprintf-gnu-tests: New file.

10 months agovdzprintf-gnu: New module.
Bruno Haible [Sun, 30 Jun 2024 15:28:59 +0000 (17:28 +0200)]
vdzprintf-gnu: New module.

* modules/vdzprintf-gnu: New file.

10 months agodzprintf-posix: Add tests.
Bruno Haible [Sun, 30 Jun 2024 15:25:46 +0000 (17:25 +0200)]
dzprintf-posix: Add tests.

* tests/test-dprintf-posix.h: New file, extracted from
tests/test-dprintf-posix.c.
* tests/test-dprintf-posix.c: Include it. Don't include infinity.h.
(test_function): Remove function.
* modules/dprintf-posix-tests (Files): Add it.
* tests/test-dzprintf-posix.c: New file, based on
tests/test-dprintf-posix.c.
* tests/test-dzprintf-posix.sh: New file, based on
tests/test-dprintf-posix.sh.
* modules/dzprintf-posix-tests: New file.

10 months agodzprintf-posix: New module.
Bruno Haible [Sun, 30 Jun 2024 15:25:05 +0000 (17:25 +0200)]
dzprintf-posix: New module.

* modules/dzprintf-posix: New file.

10 months agovdzprintf-posix: Add tests.
Bruno Haible [Sun, 30 Jun 2024 15:21:04 +0000 (17:21 +0200)]
vdzprintf-posix: Add tests.

* tests/test-fprintf-posix.h (test_function): Use RETTYPE instead of
'int'.
* tests/test-fprintf-posix.c (RETTYPE): New macro.
* tests/test-vdprintf-posix.c (RETTYPE): New macro.
* tests/test-vfprintf-posix.c (RETTYPE): New macro.
* tests/test-xfprintf-posix.c (RETTYPE): New macro.
* tests/test-vdzprintf-posix.c: New file, based on
tests/test-vdprintf-posix.c.
* tests/test-vdzprintf-posix.sh: New file, based on
tests/test-vdprintf-posix.sh.
* modules/vdzprintf-posix-tests: New file.

10 months agovdzprintf-posix: New module.
Bruno Haible [Sun, 30 Jun 2024 15:20:02 +0000 (17:20 +0200)]
vdzprintf-posix: New module.

* modules/vdzprintf-posix: New file.

10 months agodprintf: Use vdzprintf.
Bruno Haible [Sun, 30 Jun 2024 15:18:35 +0000 (17:18 +0200)]
dprintf: Use vdzprintf.

* lib/stdio.in.h (dprintf): Add specification.
* lib/dprintf.c: Don't include <stdlib.h>, full-write.h, vasnprintf.h.
Include intprops.h.
(dprintf): Implement based on vdzprintf.
* modules/dprintf (Depends-on): Add vdzprintf, intprops. Remove
vasnprintf, free-posix, full-write.

10 months agodzprintf: New module.
Bruno Haible [Sun, 30 Jun 2024 15:17:14 +0000 (17:17 +0200)]
dzprintf: New module.

* lib/stdio.in.h (dzprintf): New declaration.
* lib/dzprintf.c: New file, based on lib/vdzprintf.c.
* m4/stdio_h.m4 (gl_STDIO_H_REQUIRE_DEFAULTS): Initialize
GNULIB_DZPRINTF.
* modules/stdio (Makefile.am): Substitute GNULIB_DZPRINTF.
* modules/dzprintf: New file.

10 months agovdprintf: Use vdzprintf.
Bruno Haible [Sun, 30 Jun 2024 15:15:28 +0000 (17:15 +0200)]
vdprintf: Use vdzprintf.

* lib/stdio.in.h (vdprintf): Add specification.
* lib/vdprintf.c: Don't include <stdlib.h>, full-write.h, vasnprintf.h.
Include intprops.h.
(vdprintf): Implement based on vdzprintf.
* modules/vdprintf (Depends-on): Add vdzprintf, intprops. Remove
vasnprintf, free-posix, full-write.

10 months agovdzprintf: New module.
Bruno Haible [Sun, 30 Jun 2024 15:09:24 +0000 (17:09 +0200)]
vdzprintf: New module.

* lib/stdio.in.h (vdzprintf): New declaration.
* lib/vdzprintf.c: New file, based on lib/vdprintf.c.
* m4/stdio_h.m4 (gl_STDIO_H_REQUIRE_DEFAULTS): Initialize
GNULIB_VDZPRINTF.
* modules/stdio (Makefile.am): Substitute GNULIB_VDZPRINTF.
* modules/vdzprintf: New file.

10 months ago*printf-tests: Correct test file descriptions.
Bruno Haible [Sun, 30 Jun 2024 14:16:26 +0000 (16:16 +0200)]
*printf-tests: Correct test file descriptions.

* tests/test-fprintf-gnu.h: Fix title line.
* tests/test-fprintf-posix.h: Likewise.
* tests/test-printf-gnu.h: Likewise.
* tests/test-printf-posix.h: Likewise.
* tests/test-snzprintf-gnu.h: Likewise.
* tests/test-vaszprintf-gnu.h: Likewise.

10 months ago*printf-posix-tests: Strengthen tests.
Bruno Haible [Sun, 30 Jun 2024 13:47:39 +0000 (15:47 +0200)]
*printf-posix-tests: Strengthen tests.

* tests/test-fprintf-posix.h (test_function): Test %b directive.
* tests/test-printf-posix.h (test_function): Likewise.
* tests/test-dprintf-posix.c (test_function): Likewise.
* tests/test-printf-posix.output: Update expected test result.

10 months ago*printf-{posix,gnu}: Tweak module descriptions.
Bruno Haible [Sun, 30 Jun 2024 13:41:49 +0000 (15:41 +0200)]
*printf-{posix,gnu}: Tweak module descriptions.

* modules/c-snzprintf-gnu (Description): Say "POSIX compatible", not
"POSIX compliant", since these modules don't implement the %n directive
by default any more.
* modules/c-vaszprintf-gnu (Description): Likewise.
* modules/c-vsnzprintf-gnu (Description): Likewise.
* modules/obstack-printf-posix (Description): Likewise.
* modules/obstack-zprintf-gnu (Description): Likewise.
* modules/obstack-zprintf-posix (Description): Likewise.
* modules/snzprintf-gnu (Description): Likewise.
* modules/snzprintf-posix (Description): Likewise.
* modules/szprintf-gnu (Description): Likewise.
* modules/szprintf-posix (Description): Likewise.
* modules/vaszprintf-gnu (Description): Likewise.
* modules/vaszprintf-posix (Description): Likewise.
* modules/vsnzprintf-gnu (Description): Likewise.
* modules/vsnzprintf-posix (Description): Likewise.
* modules/vszprintf-gnu (Description): Likewise.
* modules/vszprintf-posix (Description): Likewise.

10 months agostrnlen: avoid undefined memcmp behavior
Paul Eggert [Sun, 30 Jun 2024 10:27:48 +0000 (11:27 +0100)]
strnlen: avoid undefined memcmp behavior

Problem reported by Po Lu in:
https://lists.gnu.org/r/bug-gnulib/2024-06/msg00288.html
* config/srclist.txt: Don’t mention strnlen.c even in a comment,
as the Gnulib and glibc implementations have diverged for
portability reasons, and they’re never likely to merge.
* lib/strnlen.c (strnlen): Avoid undefined behavior if
the array S points to has fewer than MAXLEN bytes.

10 months agotests: Avoid warning "is_running_under_virtualbox defined but not used".
Bruno Haible [Sun, 30 Jun 2024 05:57:12 +0000 (07:57 +0200)]
tests: Avoid warning "is_running_under_virtualbox defined but not used".

* tests/virtualbox.h (is_running_under_virtualbox): Mark as possibly
unused.