aboutsummaryrefslogtreecommitdiff
path: root/src/common/crypto.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2011-01-03 12:47:14 -0500
committerNick Mathewson <nickm@torproject.org>2011-01-03 12:47:14 -0500
commitbb5f99d4dfe119f82556ba4d9385d667a8414935 (patch)
treed293ca6b963b380f3e67952dccdc57be20b96df1 /src/common/crypto.c
parent40ef9087cf7960ce00cd82aa49309f47c9eb064c (diff)
parent9ecf133686c8907baec2292ca612ee11aa18406e (diff)
downloadtor-bb5f99d4dfe119f82556ba4d9385d667a8414935.tar.gz
tor-bb5f99d4dfe119f82556ba4d9385d667a8414935.zip
Merge remote branch 'sebastian/bug2314' into maint-0.2.2
Diffstat (limited to 'src/common/crypto.c')
-rw-r--r--src/common/crypto.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/common/crypto.c b/src/common/crypto.c
index 7e4ec32686..65162618a3 100644
--- a/src/common/crypto.c
+++ b/src/common/crypto.c
@@ -1959,14 +1959,15 @@ seed_weak_rng(void)
int
crypto_seed_rng(int startup)
{
- char buf[ADD_ENTROPY];
int rand_poll_status = 0;
/* local variables */
#ifdef MS_WINDOWS
+ unsigned char buf[ADD_ENTROPY];
static int provider_set = 0;
static HCRYPTPROV provider;
#else
+ char buf[ADD_ENTROPY];
static const char *filenames[] = {
"/dev/srandom", "/dev/urandom", "/dev/random", NULL
};