Re: test-pthread-rwlock failure on Pop!_OS 22.04 LTS

2024-06-29 Thread Paul Eggert
On 6/29/24 02:48, Bruno Haible wrote: 1. Install a toolchain for creating binaries linked against musl-libc: $ sudo apt install musl-gcc 2. Create a testdir for the module 'pthread-rwlock'. 3. Build it with CC="gcc". You should still see the test failure after 10 minutes.

Re: [PATCH] tests: switch nap() to use file creation to gauge delay

2024-06-29 Thread Jeff Layton
On Sat, 2024-06-29 at 03:33 +0200, Bruno Haible wrote: > Jeff Layton wrote: > > Failure of the test-stat-time test is what triggered us to revert the > > multigrain timestamp series from the Linux kernel last October. With > > that failure, we'd sometimes see timestamps showing files being modifie

Re: a pthread_cond_timedwait bug

2024-06-29 Thread Bruno Haible
I wrote: > I turned to the VirtualBox settings, more precisely to the > "Paravirtualization" > acceleration setting. Result: > Default, KVM -> test fails occasionally (about 1 in 3 > times) > None, Legacy, Minimal, Hyper-V -> test succeeds (no failure in 20 runs) The test-p

Re: virt-manager vs. VirtualBox

2024-06-29 Thread Bruno Haible
Hi Collin, > but you might like 'virt-manager' for setting up > KVM virtual machines [1]. I can never remember all the correct flags for > qemu. But 'virt-manager' has an easy UI and configuration similar to > VirtualBox. Thanks for the suggestion. While VirtualBox has its share of bugs: - Una

rename *z*s*printf functions

2024-06-29 Thread Bruno Haible
The naming of functions that I proposed in is inconsistent: The 'z' letter comes before the 's' for the string functions but after the 'd', 'f' for the file descriptor or file stream based functions. Recall that the 'z' means es

Re: rename *z*s*printf functions

2024-06-29 Thread Paul Eggert
While we're on the subject of the *z*printf API, I was surprised to see the obstack-related functions in stdio.h. Shouldn't they be in obstack.h?

Re: bootstrap-funclib.sh: shrink or split too-long lines

2024-06-29 Thread Bruno Haible
Hi Jim, > # The subdirectory 'gnulib' does not yet exist. Clone into it. > echo "$0: getting gnulib files..." > trap cleanup_gnulib HUP INT PIPE TERM > +gnulib_url=${GNULIB_URL:-$default_gnulib_url} > shallow= > if test -z "$GNULIB_REVISION"; th

Re: obstack_printf

2024-06-29 Thread Bruno Haible
Paul Eggert wrote: > While we're on the subject of the *z*printf API, I was surprised to see > the obstack-related functions in stdio.h. Shouldn't they be in obstack.h? glibc has obstack_printf and obstack_vprintf in /usr/include/stdio.h. Gnulib's obstack* modules are intended to mimic glibc, mu

*zprintf as overrides

2024-06-29 Thread Bruno Haible
Hi Paul, In you suggested: > I'm tempted to use "#define printf zprintf" and leave most of the source > code alone. Perhaps there should be a Gnulib option for that. We can do this through one or more gnulib modules. What I'm

Re: *zprintf as overrides

2024-06-29 Thread Paul Eggert
On 6/30/24 01:27, Bruno Haible wrote: * or one module for all of them together. That might be simplest. But first let's see where it would really be useful.

Re: bootstrap-funclib.sh: shrink or split too-long lines

2024-06-29 Thread Collin Funk
Bruno Haible writes: >> +gnulib_url=${GNULIB_URL:-$default_gnulib_url} >> shallow= >> if test -z "$GNULIB_REVISION"; then > > This variable is useful; thanks. This would allow gnulib_url to be set in bootstrap.conf so a mirror could be used right? Even before the recen

Re: GNULIB_URL and mirrors

2024-06-29 Thread Bruno Haible
Hi Collin, > >> +gnulib_url=${GNULIB_URL:-$default_gnulib_url} > >> shallow= > >> if test -z "$GNULIB_REVISION"; then > > > > This variable is useful; thanks. > > This would allow gnulib_url to be set in bootstrap.conf so a mirror > could be used right? No, setting gnul

Re: Integer overflows in memchr

2024-06-29 Thread Po Lu
Po Lu writes: > Btw, doesn't this also mean that lib/strnlen.c (in Emacs, at least) is > incorrect? > > size_t > strnlen (const char *string, size_t maxlen) > { > const char *end = memchr (string, '\0', maxlen); > return end ? (size_t) (end - string) : maxlen; > } > > is virtually identical t

Re: bootstrap-funclib.sh: shrink or split too-long lines

2024-06-29 Thread Jim Meyering
On Sat, Jun 29, 2024 at 5:11 PM Bruno Haible wrote: > 2024-06-29 Bruno Haible > > bootstrap-funclib.sh: Restore readability. > * top/bootstrap-funclib.sh (prepare_GNULIB_SRCDIR): Add a line break > instead of removing spaces. > * build-aux/bootstrap: Regenerated.

Re: a pthread_cond_timedwait bug

2024-06-29 Thread Bruno Haible
> * tests/virtualbox.h: New file. This produces compiler warnings on non-Linux platforms. Fixed through: 2024-06-30 Bruno Haible tests: Avoid warning "is_running_under_virtualbox defined but not used". * tests/virtualbox.h (is_running_under_virtualbox): Mark as possibly