diff options
author | Nick Mathewson <nickm@torproject.org> | 2010-11-29 15:53:33 -0500 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2010-11-29 16:00:47 -0500 |
commit | 89e97bdf940d6c063fc9860306395c500d1c7027 (patch) | |
tree | 4363f41168ede3a9aa6da61cfc8282508b84568d /src/common/compat.h | |
parent | 0eafe23ff38dd895c15b2deba70e5df997cf97e9 (diff) | |
download | tor-89e97bdf940d6c063fc9860306395c500d1c7027.tar.gz tor-89e97bdf940d6c063fc9860306395c500d1c7027.zip |
Add wrappers function for libc random()
On windows, it's called something different.
Diffstat (limited to 'src/common/compat.h')
-rw-r--r-- | src/common/compat.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/common/compat.h b/src/common/compat.h index 7d59501e2b..449bf748f4 100644 --- a/src/common/compat.h +++ b/src/common/compat.h @@ -480,6 +480,11 @@ typedef enum { SOCKS5_ADDRESS_TYPE_NOT_SUPPORTED = 0x08, } socks5_reply_status_t; +/* ===== Insecure rng */ +void tor_init_weak_random(unsigned seed); +long tor_weak_random(void); +#define TOR_RAND_MAX (RAND_MAX) + /* ===== OS compatibility */ const char *get_uname(void); |