From 43b26c7b21edbc64e197f2b6ae7f0c38a166c9c9 Mon Sep 17 00:00:00 2001 From: "Christoph M. Becker" Date: Wed, 2 Sep 2015 01:13:49 +0200 Subject: Fix #70395: Missing ARG_INFO for openssl_seal() This patch adds the missing ARG_INFO for the optional 5th parameter $method. --- ext/openssl/openssl.c | 3 ++- ext/openssl/tests/bug70395.phpt | 19 +++++++++++++++++++ 2 files changed, 21 insertions(+), 1 deletion(-) create mode 100644 ext/openssl/tests/bug70395.phpt (limited to 'ext/openssl') diff --git a/ext/openssl/openssl.c b/ext/openssl/openssl.c index 0421524d64..cc86f0440f 100644 --- a/ext/openssl/openssl.c +++ b/ext/openssl/openssl.c @@ -348,11 +348,12 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_openssl_verify, 0, 0, 3) ZEND_ARG_INFO(0, method) ZEND_END_ARG_INFO() -ZEND_BEGIN_ARG_INFO(arginfo_openssl_seal, 0) +ZEND_BEGIN_ARG_INFO_EX(arginfo_openssl_seal, 0, 0, 4) ZEND_ARG_INFO(0, data) ZEND_ARG_INFO(1, sealdata) ZEND_ARG_INFO(1, ekeys) /* arary */ ZEND_ARG_INFO(0, pubkeys) /* array */ + ZEND_ARG_INFO(0, method) ZEND_END_ARG_INFO() ZEND_BEGIN_ARG_INFO(arginfo_openssl_open, 0) diff --git a/ext/openssl/tests/bug70395.phpt b/ext/openssl/tests/bug70395.phpt new file mode 100644 index 0000000000..bfa881a0cd --- /dev/null +++ b/ext/openssl/tests/bug70395.phpt @@ -0,0 +1,19 @@ +--TEST-- +Bug #70395 (Missing ARG_INFO for openssl_seal()) +--SKIPIF-- + +--FILE-- +getParameters()[4]; +var_dump($param); +var_dump($param->isOptional()); +?> +--EXPECTF-- +object(ReflectionParameter)#%d (1) { + ["name"]=> + string(6) "method" +} +bool(true) -- cgit v1.2.1