[collectd] [PATCH] perl plugin: Fixed a bug in Collectd::plugin_unregister_data_set().

Sebastian Harl sh at tokkee.org
Tue Jan 29 02:10:13 CET 2008


The function tried to access a nonexistent second argument.

Signed-off-by: Sebastian Harl <sh at tokkee.org>
---
 src/perl.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/perl.c b/src/perl.c
index b87d6b7..83b407d 100644
--- a/src/perl.c
+++ b/src/perl.c
@@ -694,7 +694,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;
-- 
1.5.4.rc4.23.gcab31

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://mailman.verplant.org/pipermail/collectd/attachments/20080129/31daebfb/attachment.pgp 


More information about the collectd mailing list