From 5a223866595c0d7eb032c3c4fc3c7cd148e59f99 Mon Sep 17 00:00:00 2001 From: Florian Forster Date: Thu, 17 Dec 2015 15:13:39 +0100 Subject: [PATCH] perl plugin: Check "return value" of PERL_GET_CONTEXT. CID: 37985 --- src/perl.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/perl.c b/src/perl.c index 67cb842b..d42afc20 100644 --- a/src/perl.c +++ b/src/perl.c @@ -2509,7 +2509,10 @@ static int perl_config (oconfig_item_t *ci) int current_status = 0; if (NULL != perl_threads) - aTHX = PERL_GET_CONTEXT; + { + if ((aTHX = PERL_GET_CONTEXT) == NULL) + return -1; + } if (0 == strcasecmp (c->key, "LoadPlugin")) current_status = perl_config_loadplugin (aTHX_ c); -- 2.30.2