diff options
author | ache <ache@FreeBSD.org> | 1997-03-24 14:52:51 +0000 |
---|---|---|
committer | ache <ache@FreeBSD.org> | 1997-03-24 14:52:51 +0000 |
commit | 9548128b200ad08f41bc468dd395de099e1fa5e2 (patch) | |
tree | 896c3bd9a78c0fc5a9e3d5ad9d2bf446657cacf5 /eBones | |
parent | c9bb29c92ed68a6d09022dfc471c32ee4751d02d (diff) | |
download | FreeBSD-src-9548128b200ad08f41bc468dd395de099e1fa5e2.zip FreeBSD-src-9548128b200ad08f41bc468dd395de099e1fa5e2.tar.gz |
Use srandomdev() now
Diffstat (limited to 'eBones')
-rw-r--r-- | eBones/lib/libkrb/des_rw.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/eBones/lib/libkrb/des_rw.c b/eBones/lib/libkrb/des_rw.c index e2ac183..586b46e 100644 --- a/eBones/lib/libkrb/des_rw.c +++ b/eBones/lib/libkrb/des_rw.c @@ -35,7 +35,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $Id$ + * $Id: des_rw.c,v 1.7 1997/02/22 14:37:07 peter Exp $ */ /* @@ -230,7 +230,8 @@ des_write(fd, buf, len) */ if(!seeded) { seeded = 1; - srandom((unsigned)time(NULL)); + if (srandomdev() < 0) + srandom((unsigned long)(time(NULL) ^ getpid())); } for(i = 0 ; i < 8 ; i+= sizeof(long)) { |