[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

[Popcon-developers] Bug#462268: Bug#462268: Bug#462268: popcon: stay out of lenny for a while



On Wed, Mar 19, 2008 at 12:40:37PM +0100, Petter Reinholdtsen wrote:
> +# Select a random day to submit on, to spread the load over time, unless it is already set.
> +select_random_day() {
> +       	RANDOM=$(dd if=/dev/urandom count=1 2> /dev/null | cksum | cut -c"1-5")
> +       	DAY=$(($RANDOM % 7))
> +}

This seems overly complex: we could just replace _both_ lines by

  DAY=$(bash -c 'echo $(($RANDOM % 7))')

Cheers,
-- 
Bill. <ballombe at debian.org>

Imagine a large red swirl here. 





Reply to: