windefs: srandom() and random() for windows.
authorGurucharan Shetty <gshetty@nicira.com>
Fri, 14 Mar 2014 14:32:08 +0000 (07:32 -0700)
committerGurucharan Shetty <gshetty@nicira.com>
Mon, 17 Mar 2014 21:20:49 +0000 (14:20 -0700)
Windows does not have a srandom() and random(). But it does
have a srand() and rand(). We use these functions in sflow code.

Signed-off-by: Gurucharan Shetty <gshetty@nicira.com>
Acked-by: Ben Pfaff <blp@nicira.com>
include/windows/windefs.h

index 6f173b3..2497c4b 100644 (file)
@@ -39,4 +39,7 @@ typedef int pid_t;
 
 char *strsep(char **stringp, const char *delim);
 
+#define srandom srand
+#define random rand
+
 #endif /* windefs.h */