On 32-bit systems, the random array indexes were sometimes negative as a result of converting an int64 to int. Fixes #7.