* Issue in man page random_r.3
@ 2025-08-24 14:48 Helge Kreutzmann
2025-08-24 16:08 ` Alejandro Colomar
0 siblings, 1 reply; 6+ messages in thread
From: Helge Kreutzmann @ 2025-08-24 14:48 UTC (permalink / raw)
To: alx; +Cc: mario.blaettermann, linux-man
Without further ado, the following was found:
Issue: comma after B<initstate>(3) as in previous paragraph?
"The B<initstate_r>() function is like B<initstate>(3) except that it "
"initializes the state in the object pointed to by I<buf>, rather than "
"initializing the global state variable. Before calling this function, the "
"I<buf.state> field must be initialized to NULL. The B<initstate_r>() "
"function records a pointer to the I<statebuf> argument inside the structure "
"pointed to by I<buf>. Thus, I<statebuf> should not be deallocated so long "
"as I<buf> is still in use. (So, I<statebuf> should typically be allocated "
"as a static variable, or allocated on the heap using B<malloc>(3) or "
"similar.)"
^ permalink raw reply [flat|nested] 6+ messages in thread
* Issue in man page random_r.3
@ 2025-08-24 14:48 Helge Kreutzmann
2025-08-24 19:13 ` Alejandro Colomar
0 siblings, 1 reply; 6+ messages in thread
From: Helge Kreutzmann @ 2025-08-24 14:48 UTC (permalink / raw)
To: alx; +Cc: mario.blaettermann, linux-man
Without further ado, the following was found:
Issue 1: comma after B<initstate>(3) as in paragraph two up?
Issue 2: The function prototype above do not mention I<state>?
"The B<setstate_r>() function is like B<setstate>(3) except that it "
"modifies the state in the object pointed to by I<buf>, rather than modifying "
"the global state variable. I<state> must first have been initialized using "
"B<initstate_r>() or be the result of a previous call of B<setstate_r>()."
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Issue in man page random_r.3
2025-08-24 14:48 Helge Kreutzmann
@ 2025-08-24 16:08 ` Alejandro Colomar
0 siblings, 0 replies; 6+ messages in thread
From: Alejandro Colomar @ 2025-08-24 16:08 UTC (permalink / raw)
To: Helge Kreutzmann; +Cc: mario.blaettermann, linux-man
[-- Attachment #1: Type: text/plain, Size: 947 bytes --]
Hi Helge,
On Sun, Aug 24, 2025 at 02:48:49PM +0000, Helge Kreutzmann wrote:
> Without further ado, the following was found:
>
> Issue: comma after B<initstate>(3) as in previous paragraph?
Thanks! I've applied a fix.
Cheers,
Alex
>
> "The B<initstate_r>() function is like B<initstate>(3) except that it "
> "initializes the state in the object pointed to by I<buf>, rather than "
> "initializing the global state variable. Before calling this function, the "
> "I<buf.state> field must be initialized to NULL. The B<initstate_r>() "
> "function records a pointer to the I<statebuf> argument inside the structure "
> "pointed to by I<buf>. Thus, I<statebuf> should not be deallocated so long "
> "as I<buf> is still in use. (So, I<statebuf> should typically be allocated "
> "as a static variable, or allocated on the heap using B<malloc>(3) or "
> "similar.)"
--
<https://www.alejandro-colomar.es/>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Issue in man page random_r.3
2025-08-24 14:48 Helge Kreutzmann
@ 2025-08-24 19:13 ` Alejandro Colomar
0 siblings, 0 replies; 6+ messages in thread
From: Alejandro Colomar @ 2025-08-24 19:13 UTC (permalink / raw)
To: Helge Kreutzmann; +Cc: mario.blaettermann, linux-man, Carlos O'Donell
[-- Attachment #1: Type: text/plain, Size: 840 bytes --]
[CC += Carlos]
Hi Helge,
On Sun, Aug 24, 2025 at 02:48:49PM +0000, Helge Kreutzmann wrote:
> Without further ado, the following was found:
>
> Issue 1: comma after B<initstate>(3) as in paragraph two up?
> Issue 2: The function prototype above do not mention I<state>?
>
> "The B<setstate_r>() function is like B<setstate>(3) except that it "
> "modifies the state in the object pointed to by I<buf>, rather than modifying "
> "the global state variable. I<state> must first have been initialized using "
> "B<initstate_r>() or be the result of a previous call of B<setstate_r>()."
I don't know. I've never used that API, so we'd need the help of an
implementor or a user to know what the page intended to say.
Thanks for the report!
Have a lovely night!
Alex
--
<https://www.alejandro-colomar.es/>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
* Issue in man page random_r.3
@ 2025-12-24 14:38 Helge Kreutzmann
2025-12-25 20:42 ` Alejandro Colomar
0 siblings, 1 reply; 6+ messages in thread
From: Helge Kreutzmann @ 2025-12-24 14:38 UTC (permalink / raw)
To: alx; +Cc: mario.blaettermann, linux-man
Without further ado, the following was found:
Issue: The function prototype above do not mention I<state>?
"The B<setstate_r>() function is like B<setstate>(3), except that it "
"modifies the state in the object pointed to by I<buf>, rather than modifying "
"the global state variable. I<state> must first have been initialized using "
"B<initstate_r>() or be the result of a previous call of B<setstate_r>()."
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: Issue in man page random_r.3
2025-12-24 14:38 Issue in man page random_r.3 Helge Kreutzmann
@ 2025-12-25 20:42 ` Alejandro Colomar
0 siblings, 0 replies; 6+ messages in thread
From: Alejandro Colomar @ 2025-12-25 20:42 UTC (permalink / raw)
To: Helge Kreutzmann; +Cc: mario.blaettermann, linux-man
[-- Attachment #1: Type: text/plain, Size: 819 bytes --]
Hi Helge,
On Wed, Dec 24, 2025 at 02:38:24PM +0000, Helge Kreutzmann wrote:
> Without further ado, the following was found:
>
> Issue: The function prototype above do not mention I<state>?
>
> "The B<setstate_r>() function is like B<setstate>(3), except that it "
> "modifies the state in the object pointed to by I<buf>, rather than modifying "
> "the global state variable. I<state> must first have been initialized using "
> "B<initstate_r>() or be the result of a previous call of B<setstate_r>()."
I still have no clue of what that means. We'll have to continue living
in ignorance until someone who knows this set of APIs comes and fixes
the documentation. I've never used random_r(3) myself, so I can't help.
Have a lovely night!
Alex
--
<https://www.alejandro-colomar.es>
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2025-12-25 20:42 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-12-24 14:38 Issue in man page random_r.3 Helge Kreutzmann
2025-12-25 20:42 ` Alejandro Colomar
-- strict thread matches above, loose matches on Subject: below --
2025-08-24 14:48 Helge Kreutzmann
2025-08-24 16:08 ` Alejandro Colomar
2025-08-24 14:48 Helge Kreutzmann
2025-08-24 19:13 ` Alejandro Colomar
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox