Bug#537952: Use more random random seed than localtime

Don Armstrong don at debian.org
Wed Jul 22 10:26:22 UTC 2009


tag 537952 patch
thanks

On Wed, 22 Jul 2009, Damyan Ivanov wrote:
> I believe the patch Don is about to send will require smaller
> changes. Having some conditional code would be nice so that it
> doesn't break 5.8 installs, but that's it. Then we forward it
> upstream and let them decide.

Attached is the fairly trivial change to do this; it's still not
optimal, as it doesn't check to see if Perl_seed() exists, but it does
in everything >= etch, so I'll leave that hackery to the upstream
maintainer.

$ for a in $(seq 1 50); do perl -MMath::Random=random_uniform -e 'print join(q( ), random_uniform(4)),qq(\n)'; done;
0.472561613734689 0.112694144518581 0.760243861293759 0.526104011907634
0.388301777190366 0.728964738530108 0.301970477061109 0.0450226752212864
0.535010305454897 0.540846363162594 0.533076974242713 0.881823355311055
0.0191560004038085 0.683769973982334 0.933477654282749 0.188419398393319
[...]


Don Armstrong

-- 
Nothing is as inevitable as a mistake whose time has come.
 -- Tussman's Law

http://www.donarmstrong.com              http://rzlab.ucr.edu
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fix_for_537952.diff
Type: text/x-diff
Size: 1367 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pkg-perl-maintainers/attachments/20090722/a6c00764/attachment.diff>


More information about the pkg-perl-maintainers mailing list