diff options
author | tomsmeding <tom.smeding@gmail.com> | 2017-03-17 18:06:30 +0100 |
---|---|---|
committer | tomsmeding <tom.smeding@gmail.com> | 2017-03-17 18:06:30 +0100 |
commit | d9d996c5caf7d4332f41f06aa44806fe9d33fe96 (patch) | |
tree | 00d68eec4f59c4c3fb2f4dd1388f930c6ce6e8f0 | |
parent | 62b038cde3c8178b62ecbae1237046bec80dff4f (diff) |
srandomdev monkeypatch
-rw-r--r-- | main.c | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -118,6 +118,13 @@ static bool server_socket_callback(int fd){ return false; } +#ifndef __APPLE__ +#include <sys/time.h> +void srandomdev(void){ + srandom(time(NULL)); +} +#endif + int main(void){ srandomdev(); |