master ohmu/fastfetch-openbsd / src / detection / loadavg / loadavg_sunos.c
ohmu  ·  2026-10-15
 1#include "detection/loadavg/loadavg.h"
 2
 3#if __has_include(<sys/loadavg.h>)
 4    #include <sys/loadavg.h>
 5#else
 6    #include <stdlib.h>
 7#endif
 8
 9const char* ffDetectLoadavg(double result[3]) {
10    return getloadavg(result, 3) == 3 ? nullptr : "getloadavg() failed";
11}