diff options
| author | Noah Misch | 2015-12-05 08:04:17 +0000 |
|---|---|---|
| committer | Noah Misch | 2015-12-05 08:04:30 +0000 |
| commit | 0d46bdde2b59e67446e10165e487935a54dfd225 (patch) | |
| tree | 66c4b37c18d3a47f8db91e49a28d78b559724fcd | |
| parent | d3762fe6c208c4f5e66db24a10ddc549e9e08e0f (diff) | |
Instruct Coverity using an assertion.
This should make Coverity deduce that plperl_call_perl_func() does not
dereference NULL argtypes. Back-patch to 9.5, where the affected code
was introduced.
Michael Paquier
| -rw-r--r-- | src/pl/plperl/plperl.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/pl/plperl/plperl.c b/src/pl/plperl/plperl.c index 549034f7640..300feb018f9 100644 --- a/src/pl/plperl/plperl.c +++ b/src/pl/plperl/plperl.c @@ -2111,8 +2111,10 @@ plperl_call_perl_func(plperl_proc_desc *desc, FunctionCallInfo fcinfo) PUSHMARK(SP); EXTEND(sp, desc->nargs); + /* Get signature for true functions; inline blocks have no args. */ if (fcinfo->flinfo->fn_oid) get_func_signature(fcinfo->flinfo->fn_oid, &argtypes, &nargs); + Assert(nargs == desc->nargs); for (i = 0; i < desc->nargs; i++) { |
