diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2014-12-09 19:50:27 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2014-12-09 19:50:27 +0000 |
commit | 1a6c1df2a699df57fe6298efe01c7ed0a981ce04 (patch) | |
tree | 2f4d44b29af293e54bb64f252b3084e1d501d2c8 /lib/libc/stdlib | |
parent | 9a184bf853688eae450c938dee953c7c1bce0d0c (diff) |
random seed buffer must be unsigned
Diffstat (limited to 'lib/libc/stdlib')
-rw-r--r-- | lib/libc/stdlib/drand48.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libc/stdlib/drand48.c b/lib/libc/stdlib/drand48.c index bbeedf8a8ac..e7cb3cb71c7 100644 --- a/lib/libc/stdlib/drand48.c +++ b/lib/libc/stdlib/drand48.c @@ -1,4 +1,4 @@ -/* $OpenBSD: drand48.c,v 1.4 2014/12/08 21:45:20 deraadt Exp $ */ +/* $OpenBSD: drand48.c,v 1.5 2014/12/09 19:50:26 deraadt Exp $ */ /* * Copyright (c) 1993 Martin Birgmeier * All rights reserved. @@ -20,7 +20,7 @@ double drand48(void) { if (__rand48_deterministic == 0) { - short rseed[3]; + unsigned short rseed[3]; arc4random_buf(rseed, sizeof rseed); return ldexp((double) rseed[0], -48) + |