perl plugin: Fixed a bug in Collectd::plugin_unregister_data_set().
authorSebastian Harl <sh@tokkee.org>
Tue, 29 Jan 2008 01:10:13 +0000 (02:10 +0100)
committerFlorian Forster <octo@huhu.verplant.org>
Mon, 4 Feb 2008 16:40:24 +0000 (17:40 +0100)
The function tried to access a nonexistent second argument.

Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
src/perl.c

index 346f960..c308e8c 100644 (file)
@@ -827,7 +827,7 @@ static XS (Collectd_plugin_unregister_ds)
        log_debug ("Collectd::plugin_unregister_data_set: type = \"%s\"",
                        SvPV_nolen (ST (0)));
 
-       if (0 == pplugin_unregister_data_set (SvPV_nolen (ST (1))))
+       if (0 == pplugin_unregister_data_set (SvPV_nolen (ST (0))))
                XSRETURN_YES;
        else
                XSRETURN_EMPTY;