Fixed unsigned long problem

(now you can't do quite as many repeats any more ;-)