cvs: ZendEngine2 / zend_builtin_functions.c

From: Date: Wed, 08 May 2002 14:10:30 +0000
Subject: cvs: ZendEngine2 / zend_builtin_functions.c
Groups: php.zend-engine.cvs 
Request: Send a blank email to php-zend-engine-cvs+get-102@lists.php.net to get a copy of this message
derick Wed May 8 10:10:30 2002 EDT Modified files: /ZendEngine2 zend_builtin_functions.c Log: - MFZE1 Index: ZendEngine2/zend_builtin_functions.c diff -u ZendEngine2/zend_builtin_functions.c:1.120 ZendEngine2/zend_builtin_functions.c:1.121 --- ZendEngine2/zend_builtin_functions.c:1.120 Tue May 7 14:42:13 2002 +++ ZendEngine2/zend_builtin_functions.c Wed May 8 10:10:30 2002 @@ -180,6 +180,11 @@ convert_to_long_ex(z_requested_offset); requested_offset = (*z_requested_offset)->value.lval; + if (requested_offset < 0) { + zend_error(E_WARNING, "func_get_arg(): The argument number should be >= 0"); + RETURN_FALSE; + } + p = EG(argument_stack).top_element-1-1; arg_count = (ulong) *p; /* this is the amount of arguments passed to func_get_arg(); */ p -= 1+arg_count;

« previous php.zend-engine.cvs (#102) next »