[PATCH v5] posix: Sync tempname with gnulib
Andreas Schwab
schwab@suse.de
Wed Apr 17 12:26:00 GMT 2024
On Apr 10 2024, Adhemerval Zanella wrote:
> @@ -299,25 +246,23 @@ try_tempname_len (char *tmpl, int suffixlen, void *args,
> {
> if (vdigits == 0)
> {
> - do
> - {
> - v = random_bits (v, use_getrandom);
> - use_getrandom = true;
> - }
> - while (unfair_min <= v);
v >= unfair_min
> + /* Worry about bias only if the bits are high quality. */
> + while (random_bits (&v, v) && biased_min <= v)
v >= biased_min
--
Andreas Schwab, SUSE Labs, schwab@suse.de
GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE 1748 E4D4 88E3 0EEA B9D7
"And now for something completely different."
More information about the Libc-alpha
mailing list