[PATCH] Use arc4random instead of rand where available

Tiago Vignatti tiago.vignatti at nokia.com
Tue Mar 23 04:22:00 PDT 2010

On Tue, Mar 23, 2010 at 01:49:35AM +0100, ext Jeremy Huddleston wrote:
> I was thinking smaller would be more "acceptable" ... but I too would  
> prefer something like OsRandom() in os/utils.c ... is that something  
> that should be exported to drivers or just internal to the server?

Not sure if drivers will want this definition, so I'd wouldn't put exported
for them now.

And maybe two definitions inside window.c and exa_glyphs.c scopes sounds
better to avoid unnecessarily global references. Something like:

#define OSRAND(x) arc4random(x)
#define OSRAND(x) rand(x)

Well, I guess one would suggest this trick inside autoconf foo...



More information about the xorg-devel mailing list