Code

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 346f9601f07dc4250a57b9f5e74520e3d0e358f2..c308e8cc234ce24b53b11487d36e7418e9889fd2 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;