diff options
Diffstat (limited to 'components')
-rw-r--r-- | components/cpu.c | 12 | ||||
-rw-r--r-- | components/entropy.c | 4 | ||||
-rw-r--r-- | components/hostname.c | 2 | ||||
-rw-r--r-- | components/kernel_release.c | 2 | ||||
-rw-r--r-- | components/keymap.c | 2 | ||||
-rw-r--r-- | components/load_avg.c | 2 | ||||
-rw-r--r-- | components/ram.c | 24 | ||||
-rw-r--r-- | components/swap.c | 24 | ||||
-rw-r--r-- | components/uptime.c | 2 | ||||
-rw-r--r-- | components/user.c | 6 |
10 files changed, 40 insertions, 40 deletions
diff --git a/components/cpu.c b/components/cpu.c index a5fabf8..254f047 100644 --- a/components/cpu.c +++ b/components/cpu.c @@ -8,7 +8,7 @@ #if defined(__linux__) const char * - cpu_freq(void) + cpu_freq(const char *unused) { uintmax_t freq; @@ -22,7 +22,7 @@ } const char * - cpu_perc(void) + cpu_perc(const char *unused) { static long double a[7]; long double b[7], sum; @@ -55,7 +55,7 @@ #include <sys/sysctl.h> const char * - cpu_freq(void) + cpu_freq(const char *unused) { int freq, mib[2]; size_t size; @@ -75,7 +75,7 @@ } const char * - cpu_perc(void) + cpu_perc(const char *unused) { int mib[2]; static uintmax_t a[CPUSTATES]; @@ -115,7 +115,7 @@ #include <devstat.h> const char * - cpu_freq(void) + cpu_freq(const char *unused) { int freq; size_t size; @@ -132,7 +132,7 @@ } const char * - cpu_perc(void) + cpu_perc(const char *unused) { size_t size; static long a[CPUSTATES]; diff --git a/components/entropy.c b/components/entropy.c index cf60bc3..0544749 100644 --- a/components/entropy.c +++ b/components/entropy.c @@ -7,7 +7,7 @@ #include "../util.h" const char * - entropy(void) + entropy(const char *unused) { uintmax_t num; @@ -20,7 +20,7 @@ } #elif defined(__OpenBSD__) | defined(__FreeBSD__) const char * - entropy(void) + entropy(const char *unused) { /* Unicode Character 'INFINITY' (U+221E) */ return "\xe2\x88\x9e"; diff --git a/components/hostname.c b/components/hostname.c index 8627a88..f04a913 100644 --- a/components/hostname.c +++ b/components/hostname.c @@ -6,7 +6,7 @@ #include "../slstatus.h" const char * -hostname(void) +hostname(const char *unused) { if (gethostname(buf, sizeof(buf)) < 0) { warn("gethostbyname:"); diff --git a/components/kernel_release.c b/components/kernel_release.c index 76a3827..e21fefe 100644 --- a/components/kernel_release.c +++ b/components/kernel_release.c @@ -6,7 +6,7 @@ #include "../slstatus.h" const char * -kernel_release(void) +kernel_release(const char *unused) { struct utsname udata; diff --git a/components/keymap.c b/components/keymap.c index 87036db..2a99474 100644 --- a/components/keymap.c +++ b/components/keymap.c @@ -47,7 +47,7 @@ get_layout(char *syms, int grp_num) } const char * -keymap(void) +keymap(const char *unused) { Display *dpy; XkbDescRec *desc; diff --git a/components/load_avg.c b/components/load_avg.c index 2b523e7..ab33fa3 100644 --- a/components/load_avg.c +++ b/components/load_avg.c @@ -6,7 +6,7 @@ #include "../slstatus.h" const char * -load_avg(void) +load_avg(const char *unused) { double avgs[3]; diff --git a/components/ram.c b/components/ram.c index 3fa78af..d90b107 100644 --- a/components/ram.c +++ b/components/ram.c @@ -8,7 +8,7 @@ #include <stdint.h> const char * - ram_free(void) + ram_free(const char *unused) { uintmax_t free; @@ -24,7 +24,7 @@ } const char * - ram_perc(void) + ram_perc(const char *unused) { uintmax_t total, free, buffers, cached; @@ -47,7 +47,7 @@ } const char * - ram_total(void) + ram_total(const char *unused) { uintmax_t total; @@ -60,7 +60,7 @@ } const char * - ram_used(void) + ram_used(const char *unused) { uintmax_t total, free, buffers, cached; @@ -102,7 +102,7 @@ } const char * - ram_free(void) + ram_free(const char *unused) { struct uvmexp uvmexp; int free_pages; @@ -117,7 +117,7 @@ } const char * - ram_perc(void) + ram_perc(const char *unused) { struct uvmexp uvmexp; int percent; @@ -131,7 +131,7 @@ } const char * - ram_total(void) + ram_total(const char *unused) { struct uvmexp uvmexp; @@ -145,7 +145,7 @@ } const char * - ram_used(void) + ram_used(const char *unused) { struct uvmexp uvmexp; @@ -164,7 +164,7 @@ #include <vm/vm_param.h> const char * - ram_free(void) { + ram_free(const char *unused) { struct vmtotal vm_stats; int mib[] = {CTL_VM, VM_TOTAL}; size_t len; @@ -178,7 +178,7 @@ } const char * - ram_total(void) { + ram_total(const char *unused) { unsigned int npages; size_t len; @@ -191,7 +191,7 @@ } const char * - ram_perc(void) { + ram_perc(const char *unused) { unsigned int npages; unsigned int active; size_t len; @@ -209,7 +209,7 @@ } const char * - ram_used(void) { + ram_used(const char *unused) { unsigned int active; size_t len; diff --git a/components/swap.c b/components/swap.c index 98983ee..2e8a6fb 100644 --- a/components/swap.c +++ b/components/swap.c @@ -59,7 +59,7 @@ } const char * - swap_free(void) + swap_free(const char *unused) { long free; @@ -71,7 +71,7 @@ } const char * - swap_perc(void) + swap_perc(const char *unused) { long total, free, cached; @@ -83,7 +83,7 @@ } const char * - swap_total(void) + swap_total(const char *unused) { long total; @@ -95,7 +95,7 @@ } const char * - swap_used(void) + swap_used(const char *unused) { long total, free, cached; @@ -148,7 +148,7 @@ } const char * - swap_free(void) + swap_free(const char *unused) { int total, used; @@ -160,7 +160,7 @@ } const char * - swap_perc(void) + swap_perc(const char *unused) { int total, used; @@ -176,7 +176,7 @@ } const char * - swap_total(void) + swap_total(const char *unused) { int total, used; @@ -188,7 +188,7 @@ } const char * - swap_used(void) + swap_used(const char *unused) { int total, used; @@ -226,7 +226,7 @@ } const char * - swap_free(void) + swap_free(const char *unused) { struct kvm_swap swap_info[1]; long used, total; @@ -241,7 +241,7 @@ } const char * - swap_perc(void) + swap_perc(const char *unused) { struct kvm_swap swap_info[1]; long used, total; @@ -256,7 +256,7 @@ } const char * - swap_total(void) + swap_total(const char *unused) { struct kvm_swap swap_info[1]; long total; @@ -270,7 +270,7 @@ } const char * - swap_used(void) + swap_used(const char *unused) { struct kvm_swap swap_info[1]; long used; diff --git a/components/uptime.c b/components/uptime.c index fc3d204..99d1eda 100644 --- a/components/uptime.c +++ b/components/uptime.c @@ -15,7 +15,7 @@ #endif const char * -uptime(void) +uptime(const char *unused) { char warn_buf[256]; uintmax_t h, m; diff --git a/components/user.c b/components/user.c index fbe6814..770f5af 100644 --- a/components/user.c +++ b/components/user.c @@ -8,13 +8,13 @@ #include "../slstatus.h" const char * -gid(void) +gid(const char *unused) { return bprintf("%d", getgid()); } const char * -username(void) +username(const char *unused) { struct passwd *pw; @@ -27,7 +27,7 @@ username(void) } const char * -uid(void) +uid(const char *unused) { return bprintf("%d", geteuid()); } |