X-Git-Url: https://git.xinqibao.xyz/slstatus.git/blobdiff_plain/e79d4932ea413c277425ff92c456741e0730c3d6..932f65c37388220298b44c65e601c593e4e40b9e:/components/entropy.c diff --git a/components/entropy.c b/components/entropy.c index 65c65a1..2baa8aa 100644 --- a/components/entropy.c +++ b/components/entropy.c @@ -1,15 +1,18 @@ /* See LICENSE file for copyright and license details. */ #if defined(__linux__) -#include + #include -#include "../util.h" + #include "../util.h" -const char * -entropy(void) -{ - int num; + const char * + entropy(void) + { + int num; - return (pscanf("/proc/sys/kernel/random/entropy_avail", "%d", &num) == 1) ? - bprintf("%d", num) : NULL; -} + return (pscanf("/proc/sys/kernel/random/entropy_avail", + "%d", &num) == 1) ? + bprintf("%d", num) : NULL; + } +#elif defined(__OpenBSD__) + /* unimplemented */ #endif