Fix sys_get_random_number

Thanks @Nekotekina
Merge pull request #821 from tambry/sys_get_random_number-Fix

Fix sys_get_random_number