diff options
Diffstat (limited to 'src/print_cpu_usage.c')
-rw-r--r-- | src/print_cpu_usage.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/print_cpu_usage.c b/src/print_cpu_usage.c index 80944c5..26a9d4f 100644 --- a/src/print_cpu_usage.c +++ b/src/print_cpu_usage.c @@ -97,7 +97,7 @@ void print_cpu_usage(yajl_gen json_gen, char *buffer, const char *format) { continue; } - if (strncmp(walk+1, "usage", strlen("usage")) == 0) { + if (BEGINS_WITH(walk+1, "usage")) { outwalk += sprintf(outwalk, "%02d%%", diff_usage); walk += strlen("usage"); } |