| Index: mozilla/security/nss/lib/freebl/unix_rand.c
|
| ===================================================================
|
| --- mozilla/security/nss/lib/freebl/unix_rand.c (revision 180567)
|
| +++ mozilla/security/nss/lib/freebl/unix_rand.c (working copy)
|
| @@ -193,12 +193,7 @@
|
| #if defined(__sun)
|
| #if defined(__svr4) || defined(SVR4)
|
| #include <sys/systeminfo.h>
|
| -#include <sys/times.h>
|
| -#include <wait.h>
|
|
|
| -int gettimeofday(struct timeval *);
|
| -int gethostname(char *, int);
|
| -
|
| #define getdtablesize() sysconf(_SC_OPEN_MAX)
|
|
|
| static void
|
| @@ -363,10 +358,12 @@
|
| static void
|
| GiveSystemInfo(void)
|
| {
|
| +#ifndef NO_SYSINFO
|
| struct sysinfo si;
|
| if (sysinfo(&si) == 0) {
|
| RNG_RandomUpdate(&si, sizeof(si));
|
| }
|
| +#endif
|
| }
|
| #endif /* LINUX */
|
|
|
| @@ -672,11 +669,7 @@
|
| n = GetHighResClock(buf, maxbytes);
|
| maxbytes -= n;
|
|
|
| -#if defined(__sun) && (defined(_svr4) || defined(SVR4)) || defined(sony)
|
| - (void)gettimeofday(&tv);
|
| -#else
|
| (void)gettimeofday(&tv, 0);
|
| -#endif
|
| c = CopyLowBits((char*)buf+n, maxbytes, &tv.tv_usec, sizeof(tv.tv_usec));
|
| n += c;
|
| maxbytes -= c;
|
|
|