summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 1252d60)
raw | patch | inline | side by side (parent: 1252d60)
author | Sebastian Harl <sh@tokkee.org> | |
Sun, 8 Aug 2010 21:27:16 +0000 (23:27 +0200) | ||
committer | Sebastian Harl <sh@tokkee.org> | |
Sun, 8 Aug 2010 21:27:16 +0000 (23:27 +0200) |
src/collectdctl.c | patch | blob | history |
diff --git a/src/collectdctl.c b/src/collectdctl.c
index 85ad198dc63435ff87a6885795063c1a638a1208..f697e5fd27817b2b74d600e33765b2dd38f587c6 100644 (file)
--- a/src/collectdctl.c
+++ b/src/collectdctl.c
status = lcc_getval (c, &ident,
&ret_values_num, &ret_values, &ret_values_names);
- if (status != 0)
+ if (status != 0) {
+ fprintf (stderr, "ERROR: %s\n", lcc_strerror (c));
BAIL_OUT (-1);
+ }
for (i = 0; i < ret_values_num; ++i)
printf ("%s=%e\n", ret_values_names[i], ret_values[i]);
} while (0)
status = lcc_listval (c, &ret_ident, &ret_ident_num);
- if (status != 0)
+ if (status != 0) {
+ fprintf (stderr, "ERROR: %s\n", lcc_strerror (c));
BAIL_OUT (status);
+ }
for (i = 0; i < ret_ident_num; ++i) {
char id[1024];
status = lcc_identifier_to_string (c, id, sizeof (id), ret_ident + i);
if (status != 0) {
fprintf (stderr, "ERROR: listval: Failed to convert returned "
- "identifier to a string.\n");
+ "identifier to a string: %s\n", lcc_strerror (c));
continue;
}