ossp-pkg/uuid/uuid_prng.c 1.17 -> 1.18
--- uuid_prng.c 2008/02/21 08:58:45 1.17
+++ uuid_prng.c 2008/02/21 15:34:51 1.18
@@ -39,6 +39,7 @@
#include <fcntl.h>
/* own headers (part 2/2) */
+#include "uuid_time.h"
#include "uuid_prng.h"
#include "uuid_md5.h"
@@ -86,7 +87,7 @@
(*prng)->cnt = 0;
/* seed the C library PRNG once */
- (void)gettimeofday(&tv, NULL);
+ (void)time_gettimeofday(&tv, NULL);
pid = getpid();
srand((unsigned int)(
((unsigned int)pid << 16)
@@ -141,7 +142,7 @@
/* approach 2: try to gather data via weaker libc PRNG API. */
while (n > 0) {
/* gather new entropy */
- (void)gettimeofday(&(entropy.tv), NULL); /* source: libc time */
+ (void)time_gettimeofday(&(entropy.tv), NULL); /* source: libc time */
entropy.rnd = rand(); /* source: libc PRNG */
entropy.cnt = prng->cnt++; /* source: local counter */
|
|