projects
/
collectd.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
processes plugin: Fix error message.
[collectd.git]
/
src
/
contextswitch.c
diff --git
a/src/contextswitch.c
b/src/contextswitch.c
index
461fb0a
..
35ac5a3
100644
(file)
--- a/
src/contextswitch.c
+++ b/
src/contextswitch.c
@@
-85,8
+85,7
@@
static int cs_read(void) {
fh = fopen("/proc/stat", "r");
if (fh == NULL) {
fh = fopen("/proc/stat", "r");
if (fh == NULL) {
- ERROR("contextswitch plugin: unable to open /proc/stat: %s",
- sstrerror(errno, buffer, sizeof(buffer)));
+ ERROR("contextswitch plugin: unable to open /proc/stat: %s", STRERRNO);
return -1;
}
return -1;
}
@@
-126,9
+125,7
@@
static int cs_read(void) {
status =
perfstat_cpu_total(NULL, &perfcputotal, sizeof(perfstat_cpu_total_t), 1);
if (status < 0) {
status =
perfstat_cpu_total(NULL, &perfcputotal, sizeof(perfstat_cpu_total_t), 1);
if (status < 0) {
- char errbuf[1024];
- ERROR("contextswitch plugin: perfstat_cpu_total: %s",
- sstrerror(errno, errbuf, sizeof(errbuf)));
+ ERROR("contextswitch plugin: perfstat_cpu_total: %s", STRERRNO);
return -1;
}
return -1;
}