X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=src%2Fcgroups.c;h=103e70f6cb2b024fd50ef5a41da75b45b0b44a7e;hb=61a4ed99b1a5b6d371bb745933d0efc5dff9505c;hp=073bf4f3ec061c94d1bf3850191769dc1b919c4b;hpb=be126043c2be20399d7670fe194645292018bde0;p=collectd.git diff --git a/src/cgroups.c b/src/cgroups.c index 073bf4f3..103e70f6 100644 --- a/src/cgroups.c +++ b/src/cgroups.c @@ -76,12 +76,10 @@ static int read_cpuacct_procs(const char *dirname, char const *cgroup_name, return 0; snprintf(abs_path, sizeof(abs_path), "%s/%s/cpuacct.stat", dirname, - cgroup_name); + cgroup_name); fh = fopen(abs_path, "r"); if (fh == NULL) { - char errbuf[1024]; - ERROR("cgroups plugin: fopen (\"%s\") failed: %s", abs_path, - sstrerror(errno, errbuf, sizeof(errbuf))); + ERROR("cgroups plugin: fopen (\"%s\") failed: %s", abs_path, STRERRNO); return -1; } @@ -183,7 +181,7 @@ static int cgroups_config(const char *key, const char *value) { static int cgroups_read(void) { cu_mount_t *mnt_list = NULL; - _Bool cgroup_found = 0; + bool cgroup_found = 0; if (cu_mount_getlist(&mnt_list) == NULL) { ERROR("cgroups plugin: cu_mount_getlist failed.");