[Development] websockets (was RE: Qt 5.3 Feature freeze is coming quite soon...)

Tony Van Eerd tvaneerd at blackberry.com
Tue Feb 11 17:26:44 CET 2014


http://channel9.msdn.com/Events/GoingNative/2013/rand-Considered-Harmful



> -----Original Message-----
> From: development-bounces+tvaneerd=rim.com at qt-project.org
> [mailto:development-bounces+tvaneerd=rim.com at qt-project.org] On
> Behalf Of Thiago Macieira
> Sent: Tuesday, February 11, 2014 11:15 AM
> To: development at qt-project.org
> Subject: Re: [Development] websockets (was RE: Qt 5.3 Feature freeze is
> coming quite soon...)
> 
> Em ter 11 fev 2014, às 09:04:39, Konrad Rosenbaum escreveu:
> > Please don't go there. AFAIK qrand() is a function meant to be
> > equivalent to the ANSI-C rand() function. I.e. it is supposed to be
> > used by simple simulations, be fast and produce reproducable random
> > numbers when seeded with the same value.
> 
> Fast? yes.
> 
> Needs to produce reproduceable sequence? Yes, but only because of unit
> testing.
> 
> Equal to rand()? I'm not sure we need to keep that.
> 
> My idea was to simply securely pre-seed the PRNG before you had a chance
> to use it, in each thread. If you need to seed it to something constant to get
> constant results, you'd still be able to.
> 
> --
> Thiago Macieira - thiago.macieira (AT) intel.com
>   Software Architect - Intel Open Source Technology Center
> 
> _______________________________________________
> Development mailing list
> Development at qt-project.org
> http://lists.qt-project.org/mailman/listinfo/development



More information about the Development mailing list