summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 6a69ca9)
raw | patch | inline | side by side (parent: 6a69ca9)
author | Ruben Kerkhof <ruben@rubenkerkhof.com> | |
Fri, 4 Dec 2015 20:30:14 +0000 (21:30 +0100) | ||
committer | Florian Forster <octo@collectd.org> | |
Sat, 5 Dec 2015 07:50:29 +0000 (08:50 +0100) |
CID #38023
Signed-off-by: Florian Forster <octo@collectd.org>
Signed-off-by: Florian Forster <octo@collectd.org>
src/perl.c | patch | blob | history |
diff --git a/src/perl.c b/src/perl.c
index 5aa96c355b2494ace34fc361c42197f0df3cb0a6..67cb842b0b06f0c42332f4ee999e5fd45a91aac1 100644 (file)
--- a/src/perl.c
+++ b/src/perl.c
values = ST (/* stack index = */ 0);
+ if (NULL == values)
+ XSRETURN_EMPTY;
+
/* Make sure the argument is a hash reference. */
if (! (SvROK (values) && (SVt_PVHV == SvTYPE (SvRV (values))))) {
log_err ("Collectd::plugin_dispatch_values: Invalid values.");
XSRETURN_EMPTY;
}
- if (NULL == values)
- XSRETURN_EMPTY;
-
ret = pplugin_dispatch_values (aTHX_ (HV *)SvRV (values));
if (0 == ret)