diff options
author | Chris Akritidis <43294513+cakrit@users.noreply.github.com> | 2019-03-04 20:23:46 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-03-04 20:23:46 +0100 |
commit | a61a01bb2444d697393c81c8eb92633210e2a226 (patch) | |
tree | b01d932bfa48d576d7bbed31b39119a5700b7f9a | |
parent | 56ac9f514566d0cbfa6125a28c96b759d4de1ff9 (diff) |
Have the debug option set the freeipmi debug flags (#5548)
-rw-r--r-- | collectors/freeipmi.plugin/freeipmi_plugin.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/collectors/freeipmi.plugin/freeipmi_plugin.c b/collectors/freeipmi.plugin/freeipmi_plugin.c index d42ada1b4b..82a04ecd41 100644 --- a/collectors/freeipmi.plugin/freeipmi_plugin.c +++ b/collectors/freeipmi.plugin/freeipmi_plugin.c @@ -1790,7 +1790,10 @@ int main (int argc, char **argv) { _init_ipmi_config(&ipmi_config); - if(debug) fprintf(stderr, "freeipmi.plugin: calling ipmi_monitoring_init()\n"); + if(debug) { + fprintf(stderr, "freeipmi.plugin: calling ipmi_monitoring_init()\n"); + ipmimonitoring_init_flags|=IPMI_MONITORING_FLAGS_DEBUG|IPMI_MONITORING_FLAGS_DEBUG_IPMI_PACKETS; + } if(ipmi_monitoring_init(ipmimonitoring_init_flags, &errnum) < 0) fatal("ipmi_monitoring_init: %s", ipmi_monitoring_ctx_strerror(errnum)); |