Permalink
Browse files

- MFH: Added 'static' into ZEND_BEGIN_ARG_INFO_EX macro

  • Loading branch information...
1 parent df3dc8d commit fc2fb50d095d80a957117ecf52bd817a609e1dcf @felipensp felipensp committed Nov 17, 2008
Showing with 4 additions and 2,439 deletions.
  1. +2 −0 NEWS
  2. +1 −1 Zend/zend_API.h
  3. +0 −49 Zend/zend_builtin_functions.c
  4. +0 −2 Zend/zend_exceptions.c
  5. +0 −4 Zend/zend_interfaces.c
  6. +0 −10 ext/bcmath/bcmath.c
  7. +0 −7 ext/bz2/bz2.c
  8. +0 −18 ext/calendar/calendar.c
  9. +0 −32 ext/com_dotnet/com_extension.c
  10. +0 −11 ext/ctype/ctype.c
  11. +0 −18 ext/curl/interface.c
  12. +0 −65 ext/date/php_date.c
  13. +0 −15 ext/dba/dba.c
  14. +0 −2 ext/dom/attr.c
  15. +0 −1 ext/dom/cdatasection.c
  16. +0 −5 ext/dom/characterdata.c
  17. +0 −1 ext/dom/comment.c
  18. +0 −33 ext/dom/document.c
  19. +0 −2 ext/dom/documentfragment.c
  20. +0 −3 ext/dom/domconfiguration.c
  21. +0 −1 ext/dom/domerrorhandler.c
  22. +0 −4 ext/dom/domimplementation.c
  23. +0 −1 ext/dom/domimplementationlist.c
  24. +0 −2 ext/dom/domimplementationsource.c
  25. +0 −1 ext/dom/domstringlist.c
  26. +0 −19 ext/dom/element.c
  27. +0 −1 ext/dom/entityreference.c
  28. +0 −7 ext/dom/namednodemap.c
  29. +0 −2 ext/dom/namelist.c
  30. +0 −21 ext/dom/node.c
  31. +0 −1 ext/dom/nodelist.c
  32. +0 −1 ext/dom/php_dom.c
  33. +0 −1 ext/dom/processinginstruction.c
  34. +0 −2 ext/dom/string_extend.c
  35. +0 −4 ext/dom/text.c
  36. +0 −5 ext/dom/xpath.c
  37. +0 −7 ext/ereg/ereg.c
  38. +0 −4 ext/exif/exif.c
  39. +0 −9 ext/fileinfo/fileinfo.c
  40. +0 −7 ext/filter/filter.c
  41. +0 −33 ext/ftp/php_ftp.c
  42. +0 −98 ext/gd/gd.c
  43. +0 −9 ext/gettext/gettext.c
  44. +0 −40 ext/gmp/gmp.c
  45. +0 −20 ext/hash/hash.c
  46. +0 −11 ext/iconv/iconv.c
  47. +0 −63 ext/imap/php_imap.c
  48. +0 −49 ext/interbase/interbase.c
  49. +0 −4 ext/intl/collator/collator_class.c
  50. +0 −8 ext/intl/dateformat/dateformat_class.c
  51. +0 −11 ext/intl/formatter/formatter_class.c
  52. +0 −5 ext/intl/locale/locale_class.c
  53. +0 −6 ext/intl/msgformat/msgformat_class.c
  54. +0 −1 ext/intl/normalizer/normalizer_class.c
  55. +0 −43 ext/intl/php_intl.c
  56. +0 −2 ext/json/json.c
  57. +0 −38 ext/ldap/ldap.c
  58. +0 −5 ext/libxml/libxml.c
  59. +0 −54 ext/mbstring/mbstring.c
  60. +0 −36 ext/mcrypt/mcrypt.c
  61. +0 −19 ext/mssql/php_mssql.c
  62. +0 −3 ext/mysqli/mysqli_fe.c
  63. +0 −95 ext/oci8/oci8.c
  64. +0 −12 ext/odbc/birdstep.c
  65. +0 −43 ext/odbc/php_odbc.c
  66. +0 −42 ext/openssl/openssl.c
  67. +0 −17 ext/pcntl/pcntl.c
  68. +0 −8 ext/pcre/php_pcre.c
  69. +0 −1 ext/pdo/pdo.c
  70. +0 −12 ext/pdo/pdo_stmt.c
  71. +0 −82 ext/pgsql/pgsql.c
  72. +0 −31 ext/phar/phar_object.c
  73. +0 −35 ext/posix/posix.c
  74. +0 −19 ext/pspell/pspell.c
  75. +0 −13 ext/readline/readline.c
  76. +0 −2 ext/recode/recode.c
  77. +0 −38 ext/reflection/php_reflection.c
  78. +0 −14 ext/session/session.c
  79. +0 −6 ext/shmop/shmop.c
  80. +0 −3 ext/simplexml/simplexml.c
  81. +0 −23 ext/snmp/snmp.c
  82. +0 −28 ext/soap/soap.c
  83. +0 −25 ext/sockets/sockets.c
  84. +0 −13 ext/spl/php_spl.c
  85. +0 −10 ext/spl/spl_array.c
  86. +0 −21 ext/spl/spl_directory.c
  87. +0 −4 ext/spl/spl_dllist.c
  88. +0 −4 ext/spl/spl_fixedarray.c
  89. +0 −4 ext/spl/spl_heap.c
  90. +0 −23 ext/spl/spl_iterators.c
  91. +1 −13 ext/spl/spl_observer.c
  92. +0 −66 ext/sqlite/sqlite.c
  93. +0 −28 ext/sqlite3/sqlite3.c
  94. +0 −491 ext/standard/basic_functions.c
  95. +0 −3 ext/standard/user_filters.c
  96. +0 −23 ext/sybase_ct/php_sybase_ct.c
  97. +0 −7 ext/sysvmsg/sysvmsg.c
  98. +0 −4 ext/sysvsem/sysvsem.c
  99. +0 −6 ext/sysvshm/sysvshm.c
  100. +0 −25 ext/tidy/tidy.c
  101. +0 −2 ext/tokenizer/tokenizer.c
  102. +0 −6 ext/wddx/wddx.c
  103. +0 −24 ext/xml/xml.c
  104. +0 −25 ext/xmlreader/php_xmlreader.c
  105. +0 −13 ext/xmlrpc/xmlrpc-epi-php.c
  106. +0 −57 ext/xmlwriter/php_xmlwriter.c
  107. +0 −10 ext/xsl/xsltprocessor.c
  108. +0 −10 ext/zip/php_zip.c
  109. +0 −10 ext/zlib/zlib.c
  110. +0 −1 sapi/aolserver/aolserver.c
  111. +0 −10 sapi/apache/php_apache.c
  112. +0 −9 sapi/apache2filter/php_functions.c
  113. +0 −9 sapi/apache2handler/php_functions.c
  114. +0 −10 sapi/apache_hooks/php_apache.c
  115. +0 −9 sapi/milter/php_milter.c
  116. +0 −3 sapi/nsapi/nsapi.c
View
2 NEWS
@@ -32,6 +32,8 @@ PHP NEWS
- Fixed invalid calls to free when internal fileinfo magic file is used. (Scott)
- Synced changes from libmagic 4.26 to bundled libmagic. (Scott)
+- Fixed bug #46546 (Segmentation fault when using declare statement with
+ non-string value). (Felipe)
- Fixed bug #46421 (SplFileInfo not correctly handling /). (Etienne)
- Fixed bug #46331 - (Segfault when using internal fileinfo magic file on big
endian systems). (Scott)
View
@@ -101,7 +101,7 @@ typedef struct _zend_fcall_info_cache {
#define ZEND_ARG_OBJ_INFO(pass_by_ref, name, classname, allow_null) { #name, sizeof(#name)-1, #classname, sizeof(#classname)-1, 0, allow_null, pass_by_ref, 0, 0 },
#define ZEND_ARG_ARRAY_INFO(pass_by_ref, name, allow_null) { #name, sizeof(#name)-1, NULL, 0, 1, allow_null, pass_by_ref, 0, 0 },
#define ZEND_BEGIN_ARG_INFO_EX(name, pass_rest_by_reference, return_reference, required_num_args) \
- const zend_arg_info name[] = { \
+ static const zend_arg_info name[] = { \
{ NULL, 0, NULL, 0, 0, 0, pass_rest_by_reference, return_reference, required_num_args },
#define ZEND_BEGIN_ARG_INFO(name, pass_rest_by_reference) \
ZEND_BEGIN_ARG_INFO_EX(name, pass_rest_by_reference, ZEND_RETURN_VALUE, -1)
@@ -92,250 +92,201 @@ static ZEND_FUNCTION(gc_enable);
static ZEND_FUNCTION(gc_disable);
/* {{{ arginfo */
-static
ZEND_BEGIN_ARG_INFO(arginfo_zend_version, 0)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO(arginfo_gc_collect_cycles, 0)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO(arginfo_gc_enabled, 0)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO(arginfo_gc_enable, 0)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO(arginfo_gc_disable, 0)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO(arginfo_func_num_args, 0)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_func_get_arg, 0, 0, 1)
ZEND_ARG_INFO(0, arg_num)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO(arginfo_func_get_args, 0)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_strlen, 0, 0, 1)
ZEND_ARG_INFO(0, str)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_strcmp, 0, 0, 2)
ZEND_ARG_INFO(0, str1)
ZEND_ARG_INFO(0, str2)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_strncmp, 0, 0, 3)
ZEND_ARG_INFO(0, str1)
ZEND_ARG_INFO(0, str2)
ZEND_ARG_INFO(0, len)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_strcasecmp, 0, 0, 2)
ZEND_ARG_INFO(0, str1)
ZEND_ARG_INFO(0, str2)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_strncasecmp, 0, 0, 3)
ZEND_ARG_INFO(0, str1)
ZEND_ARG_INFO(0, str2)
ZEND_ARG_INFO(0, len)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_each, 0, 0, 1)
ZEND_ARG_INFO(1, arr)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_error_reporting, 0, 0, 1)
ZEND_ARG_INFO(0, new_error_level)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_define, 0, 0, 3)
ZEND_ARG_INFO(0, constant_name)
ZEND_ARG_INFO(0, value)
ZEND_ARG_INFO(0, case_insensitive)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_defined, 0, 0, 1)
ZEND_ARG_INFO(0, constant_name)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_get_class, 0, 0, 0)
ZEND_ARG_INFO(0, object)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO(arginfo_get_called_class, 0)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_get_parent_class, 0, 0, 0)
ZEND_ARG_INFO(0, object)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_is_subclass_of, 0, 0, 2)
ZEND_ARG_INFO(0, object)
ZEND_ARG_INFO(0, class_name)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_is_a, 0, 0, 2)
ZEND_ARG_INFO(0, object)
ZEND_ARG_INFO(0, class_name)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_get_class_vars, 0, 0, 1)
ZEND_ARG_INFO(0, class_name)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_get_object_vars, 0, 0, 1)
ZEND_ARG_INFO(0, obj)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_get_class_methods, 0, 0, 1)
ZEND_ARG_INFO(0, class)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_method_exists, 0, 0, 2)
ZEND_ARG_INFO(0, object)
ZEND_ARG_INFO(0, method)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_property_exists, 0, 0, 2)
ZEND_ARG_INFO(0, object_or_class)
ZEND_ARG_INFO(0, property_name)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_class_exists, 0, 0, 1)
ZEND_ARG_INFO(0, classname)
ZEND_ARG_INFO(0, autoload)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_interface_exists, 0, 0, 1)
ZEND_ARG_INFO(0, classname)
ZEND_ARG_INFO(0, autoload)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_function_exists, 0, 0, 1)
ZEND_ARG_INFO(0, function_name)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_class_alias, 0, 0, 2)
ZEND_ARG_INFO(0, user_class_name)
ZEND_ARG_INFO(0, alias_name)
ZEND_ARG_INFO(0, autoload)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO(arginfo_get_included_files, 0)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_trigger_error, 0, 0, 1)
ZEND_ARG_INFO(0, messsage)
ZEND_ARG_INFO(0, error_type)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_set_error_handler, 0, 0, 1)
ZEND_ARG_INFO(0, error_handler)
ZEND_ARG_INFO(0, error_types)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO(arginfo_restore_error_handler, 0)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_set_exception_handler, 0, 0, 1)
ZEND_ARG_INFO(0, exception_handler)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO(arginfo_restore_exception_handler, 0)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO(arginfo_get_declared_classes, 0)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO(arginfo_get_declared_interfaces, 0)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO(arginfo_get_defined_functions, 0)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO(arginfo_get_defined_vars, 0)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_create_function, 0, 0, 2)
ZEND_ARG_INFO(0, args)
ZEND_ARG_INFO(0, code)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_get_resource_type, 0, 0, 1)
ZEND_ARG_INFO(0, res)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_get_loaded_extensions, 0, 0, 0)
ZEND_ARG_INFO(0, zend_extensions)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_get_defined_constants, 0, 0, 0)
ZEND_ARG_INFO(0, categorize)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO(arginfo_debug_print_backtrace, 0)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_debug_backtrace, 0, 0, 0)
ZEND_ARG_INFO(0, provide_object)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_extension_loaded, 0, 0, 1)
ZEND_ARG_INFO(0, extension_name)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_get_extension_funcs, 0, 0, 1)
ZEND_ARG_INFO(0, extension_name)
ZEND_END_ARG_INFO()
View
@@ -605,7 +605,6 @@ ZEND_METHOD(exception, __toString)
* And never try to change the state of exceptions and never implement anything
* that gives the user anything to accomplish this.
*/
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_exception___construct, 0, 0, 0)
ZEND_ARG_INFO(0, message)
ZEND_ARG_INFO(0, code)
@@ -626,7 +625,6 @@ const static zend_function_entry default_exception_functions[] = {
{NULL, NULL, NULL}
};
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_error_exception___construct, 0, 0, 0)
ZEND_ARG_INFO(0, message)
ZEND_ARG_INFO(0, code)
View
@@ -498,17 +498,14 @@ const zend_function_entry zend_funcs_iterator[] = {
const zend_function_entry *zend_funcs_traversable = NULL;
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_arrayaccess_offset, 0, 0, 1)
ZEND_ARG_INFO(0, offset)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_arrayaccess_offset_get, 0, 0, 1) /* actually this should be return by ref but atm cannot be */
ZEND_ARG_INFO(0, offset)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_arrayaccess_offset_value, 0, 0, 2)
ZEND_ARG_INFO(0, offset)
ZEND_ARG_INFO(0, value)
@@ -522,7 +519,6 @@ const zend_function_entry zend_funcs_arrayaccess[] = {
{NULL, NULL, NULL}
};
-static
ZEND_BEGIN_ARG_INFO(arginfo_serializable_serialize, 0)
ZEND_ARG_INFO(0, serialized)
ZEND_END_ARG_INFO()
View
@@ -36,69 +36,59 @@ static PHP_GINIT_FUNCTION(bcmath);
static PHP_GSHUTDOWN_FUNCTION(bcmath);
/* {{{ arginfo */
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_bcadd, 0, 0, 2)
ZEND_ARG_INFO(0, left_operand)
ZEND_ARG_INFO(0, right_operand)
ZEND_ARG_INFO(0, scale)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_bcsub, 0, 0, 2)
ZEND_ARG_INFO(0, left_operand)
ZEND_ARG_INFO(0, right_operand)
ZEND_ARG_INFO(0, scale)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_bcmul, 0, 0, 2)
ZEND_ARG_INFO(0, left_operand)
ZEND_ARG_INFO(0, right_operand)
ZEND_ARG_INFO(0, scale)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_bcdiv, 0, 0, 2)
ZEND_ARG_INFO(0, left_operand)
ZEND_ARG_INFO(0, right_operand)
ZEND_ARG_INFO(0, scale)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO(arginfo_bcmod, 0)
ZEND_ARG_INFO(0, left_operand)
ZEND_ARG_INFO(0, right_operand)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_bcpowmod, 0, 0, 3)
ZEND_ARG_INFO(0, x)
ZEND_ARG_INFO(0, y)
ZEND_ARG_INFO(0, mod)
ZEND_ARG_INFO(0, scale)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_bcpow, 0, 0, 2)
ZEND_ARG_INFO(0, x)
ZEND_ARG_INFO(0, y)
ZEND_ARG_INFO(0, scale)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_bcsqrt, 0, 0, 1)
ZEND_ARG_INFO(0, operand)
ZEND_ARG_INFO(0, scale)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO_EX(arginfo_bccomp, 0, 0, 2)
ZEND_ARG_INFO(0, left_operand)
ZEND_ARG_INFO(0, right_operand)
ZEND_ARG_INFO(0, scale)
ZEND_END_ARG_INFO()
-static
ZEND_BEGIN_ARG_INFO(arginfo_bcscale, 0)
ZEND_ARG_INFO(0, scale)
ZEND_END_ARG_INFO()
Oops, something went wrong.

0 comments on commit fc2fb50

Please sign in to comment.