Patch my_test for Scripting Engine problem Bug #70773
Patch version 2015-10-23 03:53 UTC
Return to Bug #70773 |
Download this patch
Patch Revisions:
Developer: svein@vip.qq.com
//Segmentation fault (core dumped) when this function called
PHP_FUNCTION(my_test)
{
long type = 0;
char *function_name = NULL;
int function_name_len = 0;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ls", &type
,&function_name,&function_name_len) == FAILURE)
{
zend_error(E_ERROR, "my_test zend_parse_parameters error");
}
RETURN_LONG(1);
}
//this one is ok
PHP_FUNCTION(my_test_ok)
{
long type = 0;
char *function_name = NULL;
int function_name_len = 0;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ls", &type
,&function_name,&function_name_len) == FAILURE)
{
zend_error(E_ERROR, "my_test zend_parse_parameters error");
}
}
//this one is ok too
PHP_FUNCTION(my_test_ok2)
{
long type = 0;
char *function_name = NULL;
int function_name_len = 0;
RETURN_LONG(1);
}
|