Added test code for reading from /dev/random/
Moved to a new function.
Fixed bad parameters and wrong function call to write instead of read.
Shoehorned return value of random function into expected range.
Added random return values for every function.
Added correct return values for functions that break otherwise ^_^;;