From eeb32305ba52615d5ebd16f174679b5c919d67c3 Mon Sep 17 00:00:00 2001 From: NewEraCracker Date: Fri, 8 Apr 2016 21:51:53 +0100 Subject: Avoid having parameter warnings twice when they're incorrect --- execute.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/execute.c b/execute.c index d8b0be4..94f7b4b 100644 --- a/execute.c +++ b/execute.c @@ -674,7 +674,7 @@ int ih_preg_replace(IH_HANDLER_PARAMS) **limit, **zcount; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ZZZ|ZZ", ®ex, &replace, &subject, &limit, &zcount) == FAILURE) { - return(0); + return (1); } if (Z_TYPE_PP(regex) == IS_ARRAY) { @@ -1529,8 +1529,9 @@ static int ih_rand(IH_HANDLER_PARAMS) static int ih_getrandmax(IH_HANDLER_PARAMS) { if (zend_parse_parameters_none() == FAILURE) { - return(0); + return (1); } + RETVAL_LONG(PHP_MT_RAND_MAX); return (1); } -- cgit v1.3