From: Ruben Kerkhof Date: Wed, 20 Feb 2019 10:22:30 +0000 (+0100) Subject: turbostat plugin: fix two compiler warnings X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=739813753477497221e237d142993a90234806ec;p=collectd.git turbostat plugin: fix two compiler warnings src/turbostat.c:1466:5: warning: no previous prototype for function 'save_affinity' [-Wmissing-prototypes] int save_affinity(void) { ^ src/turbostat.c:1479:6: warning: no previous prototype for function 'restore_affinity' [-Wmissing-prototypes] void restore_affinity(void) { ^ --- diff --git a/src/turbostat.c b/src/turbostat.c index deb16e0c..ce57942d 100644 --- a/src/turbostat.c +++ b/src/turbostat.c @@ -1463,7 +1463,7 @@ err: return ret; } -int save_affinity(void) { +static int save_affinity(void) { if (affinity_policy == policy_restore_affinity) { /* Try to save the scheduling affinity, as it will be modified by * get_counters(). @@ -1476,7 +1476,7 @@ int save_affinity(void) { return 0; } -void restore_affinity(void) { +static void restore_affinity(void) { /* Let's restore the affinity to the value saved in save_affinity */ if (affinity_policy == policy_restore_affinity) (void)sched_setaffinity(0, cpu_saved_affinity_setsize,