2
0
mirror of https://github.com/sudo-project/sudo.git synced 2025-08-31 14:25:15 +00:00

Add missing #ifdef HAVE_CLOCK_GETTIME in getentropy_fallback()

From Tim Rice
This commit is contained in:
Todd C. Miller
2020-09-04 15:55:11 -06:00
parent f6d477692f
commit c4b9f6136d

View File

@@ -503,6 +503,7 @@ getentropy_fallback(void *buf, size_t len)
/ pgs);
}
#ifdef HAVE_CLOCK_GETTIME
/* Check cnts and times... */
for (ii = 0; ii < sizeof(cl)/sizeof(cl[0]);
ii++) {
@@ -511,6 +512,7 @@ getentropy_fallback(void *buf, size_t len)
if (e != -1)
cnt += (int)ts.tv_nsec;
}
#endif /* HAVE_CLOCK_GETTIME */
HX((e = getrusage(RUSAGE_SELF,
&ru)) == -1, ru);