Re: /dev/random vs. /dev/urandom

From: Andries Brouwer
Date: Fri Jan 07 2005 - 17:10:20 EST


On Fri, Jan 07, 2005 at 02:05:36PM -0500, Ron Peterson wrote:

> When I compile and run the code below, the string of octal characters
> generated by reading /dev/random contains long strings of zeroes.

But it is your program that invents the zeros, they are not returned
by /dev/random. The bug in your program is failing to check the
return value of read().
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/