This is the mail archive of the libc-help@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Why is getentropy marked with warn_unused_result?


On Sun, 23 Jul 2017, Florian Weimer wrote:

> I'm still open to implementing emulation within glibc if problems like
> these convince the glibc community that this is necessary.

I don't object to a straightforward emulation that opens /dev/urandom with 
O_CLOEXEC, does the read and closes the file, each time getentropy is 
called (if __NR_getrandom is not defined, or if the getrandom syscall 
returns an ENOSYS error).  The argument for emulation in getentropy is 
stronger than that for emulating the lower-level getrandom interface.

-- 
Joseph S. Myers
joseph@codesourcery.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]