drieuxster (drieuxster) wrote,
drieuxster
drieuxster

Must Control Fist Of Death.... ( The Random Number Generating System )

ok, so the coding standards are open to some, well, uh, interpretation in this crew. I love lines like:
# TODO: make this not suck by caching cat/grep result
never mind the reality check that the fact that we are doing a 'cat/grep'.... But when I found that they were doing this really NEAT trick with checking for /dev/srandom or /dev/random and a couple of sysopen()/sysreads(), i was AMUSED until I noticed that they were initializing the conditional variable AT THE START OF THE METHOD!!! rather than the usual solution of having it outside the function and hence

# hey kids, what if we initialize the random number gen ONCE!!!
our $rand_init = 0;
# Must HURT THEM WITH LONG FUNCTION NAME - so that it will poke
# them where it hurts and they know that they must never do that
# mistake ever AGAIN!!!
sub seedTheMindNumbingRandomNumberGeneratingSystem {
...
you know so that the function will have

seedTheMindNumbingRandomNumberGeneratingSystem()
unless ($rand_init);
...
You know - so that they are soooo painfully aware that they were just WRONG!!!

Earthlings, What ARE they doing on staff???
Tags: they_did_what
Subscribe

  • Post a new comment

    Error

    default userpic

    Your IP address will be recorded 

    When you submit the form an invisible reCAPTCHA check will be performed.
    You must follow the Privacy Policy and Google Terms of use.
  • 4 comments