X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=src%2Fperl.c;h=4a76c0aa6f636d9075057c83e39b8d6b6b5c060d;hb=ef7fec0c4e0bbbabb356e6a570ac6297ee06eb80;hp=400057b77c0b42b9dc8503336a5d233a9b003c03;hpb=671b79940f4a187ffed28a720dc782208240f0b4;p=collectd.git diff --git a/src/perl.c b/src/perl.c index 400057b7..4a76c0aa 100644 --- a/src/perl.c +++ b/src/perl.c @@ -1092,7 +1092,7 @@ static XS (Collectd_plugin_log) XSRETURN_EMPTY; } - plugin_log (SvIV (ST (0)), SvPV_nolen (ST (1))); + plugin_log (SvIV (ST (0)), "%s", SvPV_nolen (ST (1))); XSRETURN_YES; } /* static XS (Collectd_plugin_log) */ @@ -1806,7 +1806,10 @@ static int perl_config (oconfig_item_t *ci) else if (0 == strcasecmp (c->key, "Plugin")) current_status = perl_config_plugin (aTHX_ c); else + { log_warn ("Ignoring unknown config key \"%s\".", c->key); + current_status = 0; + } /* fatal error - it's up to perl_config_* to clean up */ if (0 > current_status) {