Think about Loose Coupling | |
PerlMonks |
Hashes aren't being differently randomizedby Hue-Bond (Priest) |
on Jun 26, 2006 at 17:28 UTC ( [id://557616]=perlquestion: print w/replies, xml ) | Need Help?? |
Hue-Bond has asked for the wisdom of the Perl Monks concerning the following question:
Great feature, so let's try it!
Hmm, same MD5? And what about keys and values?
This implies I'm always getting the same output, so each, keys and values are returning the elements in the same order even when the seeds are different! My Perl was compiled without -DUSE_HASH_SEED_EXPLICIT (according to $Config::Config{ccflags}) so I shouldn't be setting the seed manually but anyway I tried, just in case. I used bash's $RANDOM variable, that returns a different value each time it's evaluated:
Super Search found this but it doesn't seem to apply here since perl -V | grep SEED shows nothing. The test here also returns the same output every time I run it. This is a 5.8.8 running on Debian/Linux. Ideas? --
Back to
Seekers of Perl Wisdom
|
|