summaryrefslogtreecommitdiff
path: root/ext
diff options
context:
space:
mode:
Diffstat (limited to 'ext')
-rw-r--r--ext/bcmath/bcmath.c2
-rw-r--r--ext/bcmath/php_bcmath.h2
-rw-r--r--ext/bz2/bz2.c8
-rw-r--r--ext/bz2/bz2.dsp112
-rw-r--r--ext/bz2/bz2_filter.c14
-rw-r--r--ext/bz2/php_bz2.h2
-rw-r--r--ext/calendar/cal_unix.c2
-rw-r--r--ext/calendar/calendar.c2
-rw-r--r--ext/calendar/easter.c2
-rw-r--r--ext/com_dotnet/com_com.c9
-rw-r--r--ext/com_dotnet/com_dotnet.c2
-rw-r--r--ext/com_dotnet/com_extension.c2
-rw-r--r--ext/com_dotnet/com_handlers.c6
-rw-r--r--ext/com_dotnet/com_iterator.c2
-rw-r--r--ext/com_dotnet/com_misc.c2
-rw-r--r--ext/com_dotnet/com_olechar.c2
-rw-r--r--ext/com_dotnet/com_persist.c2
-rw-r--r--ext/com_dotnet/com_saproxy.c2
-rw-r--r--ext/com_dotnet/com_typeinfo.c2
-rw-r--r--ext/com_dotnet/com_variant.c2
-rw-r--r--ext/com_dotnet/com_wrapper.c6
-rw-r--r--ext/com_dotnet/php_com_dotnet.h2
-rw-r--r--ext/com_dotnet/php_com_dotnet_internal.h6
-rw-r--r--ext/ctype/ctype.c2
-rw-r--r--ext/ctype/ctype.dsp107
-rw-r--r--ext/ctype/php_ctype.h2
-rw-r--r--ext/curl/curl.dsp190
-rw-r--r--ext/curl/curl_file.c2
-rw-r--r--ext/curl/interface.c16
-rw-r--r--ext/curl/multi.c2
-rw-r--r--ext/curl/php_curl.h4
-rw-r--r--ext/curl/share.c2
-rw-r--r--ext/curl/tests/check_win_config.phpt4
-rw-r--r--ext/date/lib/astro.c2
-rw-r--r--ext/date/lib/dow.c2
-rw-r--r--ext/date/lib/interval.c2
-rw-r--r--ext/date/lib/parse_date.c2
-rw-r--r--ext/date/lib/parse_date.re2
-rw-r--r--ext/date/lib/parse_iso_intervals.c2
-rw-r--r--ext/date/lib/parse_iso_intervals.re2
-rw-r--r--ext/date/lib/parse_tz.c2
-rw-r--r--ext/date/lib/timelib.c5
-rw-r--r--ext/date/lib/timelib.h2
-rw-r--r--ext/date/lib/timelib_structs.h6
-rw-r--r--ext/date/lib/timezonedb.h1218
-rw-r--r--ext/date/lib/tm2unixtime.c2
-rw-r--r--ext/date/lib/unixtime2tm.c2
-rw-r--r--ext/date/php_date.c16
-rw-r--r--ext/date/php_date.h2
-rw-r--r--ext/date/tests/bug67118.phpt3
-rw-r--r--ext/date/tests/bug67118_2.phpt11
-rw-r--r--ext/dba/dba.c14
-rw-r--r--ext/dba/dba.dsp213
-rw-r--r--ext/dba/dba_cdb.c2
-rw-r--r--ext/dba/dba_db1.c2
-rw-r--r--ext/dba/dba_db2.c2
-rw-r--r--ext/dba/dba_db3.c2
-rw-r--r--ext/dba/dba_db4.c2
-rw-r--r--ext/dba/dba_dbm.c2
-rw-r--r--ext/dba/dba_flatfile.c2
-rw-r--r--ext/dba/dba_gdbm.c2
-rw-r--r--ext/dba/dba_inifile.c2
-rw-r--r--ext/dba/dba_ndbm.c2
-rw-r--r--ext/dba/dba_qdbm.c2
-rw-r--r--ext/dba/dba_tcadb.c2
-rw-r--r--ext/dba/libcdb/cdb.c2
-rw-r--r--ext/dba/libcdb/cdb.h2
-rw-r--r--ext/dba/libcdb/cdb_make.c2
-rw-r--r--ext/dba/libcdb/cdb_make.h2
-rw-r--r--ext/dba/libcdb/uint32.c2
-rw-r--r--ext/dba/libcdb/uint32.h2
-rw-r--r--ext/dba/libflatfile/flatfile.c2
-rw-r--r--ext/dba/libflatfile/flatfile.h2
-rw-r--r--ext/dba/libinifile/inifile.c2
-rw-r--r--ext/dba/libinifile/inifile.h2
-rw-r--r--ext/dba/php_dba.h2
-rw-r--r--ext/dba/php_tcadb.h2
-rw-r--r--ext/dom/attr.c2
-rw-r--r--ext/dom/cdatasection.c2
-rw-r--r--ext/dom/characterdata.c2
-rw-r--r--ext/dom/comment.c2
-rw-r--r--ext/dom/document.c2
-rw-r--r--ext/dom/documentfragment.c2
-rw-r--r--ext/dom/documenttype.c4
-rw-r--r--ext/dom/dom.dsp250
-rw-r--r--ext/dom/dom_ce.h2
-rw-r--r--ext/dom/dom_fe.h2
-rw-r--r--ext/dom/dom_iterators.c2
-rw-r--r--ext/dom/dom_properties.h2
-rw-r--r--ext/dom/domconfiguration.c2
-rw-r--r--ext/dom/domerror.c2
-rw-r--r--ext/dom/domerrorhandler.c2
-rw-r--r--ext/dom/domexception.c2
-rw-r--r--ext/dom/domimplementation.c2
-rw-r--r--ext/dom/domimplementationlist.c2
-rw-r--r--ext/dom/domimplementationsource.c2
-rw-r--r--ext/dom/domlocator.c2
-rw-r--r--ext/dom/domstringlist.c2
-rw-r--r--ext/dom/element.c2
-rw-r--r--ext/dom/entity.c2
-rw-r--r--ext/dom/entityreference.c2
-rw-r--r--ext/dom/namednodemap.c2
-rw-r--r--ext/dom/namelist.c2
-rw-r--r--ext/dom/node.c2
-rw-r--r--ext/dom/nodelist.c2
-rw-r--r--ext/dom/notation.c2
-rw-r--r--ext/dom/php_dom.c2
-rw-r--r--ext/dom/php_dom.h2
-rw-r--r--ext/dom/processinginstruction.c2
-rw-r--r--ext/dom/string_extend.c2
-rw-r--r--ext/dom/text.c2
-rw-r--r--ext/dom/typeinfo.c2
-rw-r--r--ext/dom/userdatahandler.c2
-rw-r--r--ext/dom/xml_common.h2
-rw-r--r--ext/dom/xpath.c2
-rw-r--r--ext/enchant/enchant.c2
-rw-r--r--ext/ereg/ereg.c2
-rw-r--r--ext/ereg/php_ereg.h2
-rw-r--r--ext/ereg/php_regex.h2
-rw-r--r--ext/ereg/regex/regex.dsp106
-rw-r--r--ext/ereg/regex/regex.dsw29
-rw-r--r--ext/exif/exif.c2
-rw-r--r--ext/exif/exif.dsp113
-rw-r--r--ext/exif/php_exif.h2
-rwxr-xr-xext/ext_skel4
-rw-r--r--ext/ext_skel_win32.php17
-rw-r--r--ext/fileinfo/fileinfo.c2
-rw-r--r--ext/fileinfo/libmagic/apprentice.c2
-rw-r--r--ext/fileinfo/libmagic/softmagic.c2
-rw-r--r--ext/fileinfo/php_fileinfo.h2
-rw-r--r--ext/filter/callback_filter.c2
-rw-r--r--ext/filter/filter.c2
-rw-r--r--ext/filter/filter_private.h2
-rw-r--r--ext/filter/logical_filters.c2
-rw-r--r--ext/filter/php_filter.h2
-rw-r--r--ext/filter/sanitizing_filters.c14
-rw-r--r--ext/ftp/ftp.c2
-rw-r--r--ext/ftp/ftp.h2
-rw-r--r--ext/ftp/php_ftp.c2
-rw-r--r--ext/ftp/php_ftp.h2
-rw-r--r--ext/gd/gd.c2
-rw-r--r--ext/gd/gd.dsp600
-rw-r--r--ext/gd/gd_ctx.c2
-rw-r--r--ext/gd/libgd/xbm.c2
-rw-r--r--ext/gd/php_gd.h2
-rw-r--r--ext/gd/tests/bug48801_1.phpt9
-rw-r--r--ext/gd/tests/bug48801_2.phpt25
-rw-r--r--ext/gettext/gettext.c2
-rw-r--r--ext/gettext/gettext.dsp113
-rw-r--r--ext/gettext/php_gettext.h2
-rw-r--r--ext/gmp/config.m413
-rw-r--r--ext/gmp/gmp.c49
-rw-r--r--ext/gmp/php_gmp.h2
-rw-r--r--ext/gmp/tests/bug50283.phpt1
-rw-r--r--ext/gmp/tests/gmp_clrbit.phpt5
-rw-r--r--ext/gmp/tests/gmp_setbit.phpt5
-rw-r--r--ext/hash/hash.c14
-rw-r--r--ext/hash/hash_adler32.c2
-rw-r--r--ext/hash/hash_crc32.c2
-rw-r--r--ext/hash/hash_fnv.c2
-rw-r--r--ext/hash/hash_gost.c6
-rw-r--r--ext/hash/hash_haval.c18
-rw-r--r--ext/hash/hash_joaat.c2
-rw-r--r--ext/hash/hash_md.c8
-rw-r--r--ext/hash/hash_ripemd.c18
-rw-r--r--ext/hash/hash_sha.c18
-rw-r--r--ext/hash/hash_snefru.c6
-rw-r--r--ext/hash/hash_tiger.c12
-rw-r--r--ext/hash/hash_whirlpool.c8
-rw-r--r--ext/hash/php_hash.h2
-rw-r--r--ext/hash/php_hash_adler32.h2
-rw-r--r--ext/hash/php_hash_crc32.h2
-rw-r--r--ext/hash/php_hash_crc32_tables.h2
-rw-r--r--ext/hash/php_hash_fnv.h2
-rw-r--r--ext/hash/php_hash_gost.h2
-rw-r--r--ext/hash/php_hash_haval.h2
-rw-r--r--ext/hash/php_hash_joaat.h2
-rw-r--r--ext/hash/php_hash_md.h2
-rw-r--r--ext/hash/php_hash_ripemd.h2
-rw-r--r--ext/hash/php_hash_sha.h2
-rw-r--r--ext/hash/php_hash_snefru.h2
-rw-r--r--ext/hash/php_hash_snefru_tables.h2
-rw-r--r--ext/hash/php_hash_tiger.h2
-rw-r--r--ext/hash/php_hash_tiger_tables.h2
-rw-r--r--ext/hash/php_hash_whirlpool.h2
-rw-r--r--ext/hash/php_hash_whirlpool_tables.h2
-rw-r--r--ext/iconv/iconv.c28
-rw-r--r--ext/iconv/iconv.dsp107
-rw-r--r--ext/iconv/php_iconv.h2
-rw-r--r--ext/imap/imap.dsp176
-rw-r--r--ext/imap/php_imap.c4
-rw-r--r--ext/imap/php_imap.h2
-rw-r--r--ext/interbase/ibase_blobs.c2
-rw-r--r--ext/interbase/ibase_events.c2
-rw-r--r--ext/interbase/ibase_query.c2
-rw-r--r--ext/interbase/ibase_service.c2
-rw-r--r--ext/interbase/interbase.c2
-rw-r--r--ext/interbase/interbase.dsp135
-rw-r--r--ext/interbase/php_ibase_includes.h2
-rw-r--r--ext/interbase/php_ibase_udf.c5
-rw-r--r--ext/interbase/php_interbase.h2
-rw-r--r--ext/intl/breakiterator/breakiterator_class.cpp2
-rw-r--r--ext/intl/breakiterator/breakiterator_class.h2
-rw-r--r--ext/intl/breakiterator/breakiterator_iterators.cpp2
-rw-r--r--ext/intl/breakiterator/breakiterator_iterators.h2
-rw-r--r--ext/intl/breakiterator/breakiterator_methods.cpp2
-rw-r--r--ext/intl/breakiterator/breakiterator_methods.h2
-rw-r--r--ext/intl/breakiterator/codepointiterator_internal.cpp2
-rw-r--r--ext/intl/breakiterator/codepointiterator_internal.h2
-rw-r--r--ext/intl/breakiterator/codepointiterator_methods.cpp2
-rw-r--r--ext/intl/breakiterator/codepointiterator_methods.h2
-rw-r--r--ext/intl/breakiterator/rulebasedbreakiterator_methods.cpp2
-rw-r--r--ext/intl/breakiterator/rulebasedbreakiterator_methods.h2
-rw-r--r--ext/intl/calendar/calendar_class.cpp2
-rw-r--r--ext/intl/calendar/calendar_class.h2
-rw-r--r--ext/intl/calendar/calendar_methods.cpp2
-rw-r--r--ext/intl/calendar/calendar_methods.h2
-rw-r--r--ext/intl/calendar/gregoriancalendar_methods.cpp2
-rw-r--r--ext/intl/calendar/gregoriancalendar_methods.h2
-rw-r--r--ext/intl/collator/collator.c2
-rw-r--r--ext/intl/collator/collator.h2
-rw-r--r--ext/intl/collator/collator_attr.c2
-rw-r--r--ext/intl/collator/collator_attr.h2
-rw-r--r--ext/intl/collator/collator_class.c2
-rw-r--r--ext/intl/collator/collator_class.h2
-rw-r--r--ext/intl/collator/collator_compare.c2
-rw-r--r--ext/intl/collator/collator_compare.h2
-rw-r--r--ext/intl/collator/collator_convert.c2
-rw-r--r--ext/intl/collator/collator_convert.h2
-rw-r--r--ext/intl/collator/collator_create.c2
-rw-r--r--ext/intl/collator/collator_create.h2
-rw-r--r--ext/intl/collator/collator_error.c2
-rw-r--r--ext/intl/collator/collator_error.h2
-rw-r--r--ext/intl/collator/collator_is_numeric.c2
-rw-r--r--ext/intl/collator/collator_is_numeric.h2
-rw-r--r--ext/intl/collator/collator_locale.c2
-rw-r--r--ext/intl/collator/collator_locale.h2
-rw-r--r--ext/intl/collator/collator_sort.c4
-rw-r--r--ext/intl/collator/collator_sort.h2
-rw-r--r--ext/intl/common/common_date.cpp2
-rw-r--r--ext/intl/common/common_date.h2
-rw-r--r--ext/intl/common/common_enum.cpp2
-rw-r--r--ext/intl/common/common_enum.h2
-rw-r--r--ext/intl/common/common_error.c2
-rw-r--r--ext/intl/common/common_error.h2
-rw-r--r--ext/intl/converter/converter.c2
-rw-r--r--ext/intl/converter/converter.h2
-rw-r--r--ext/intl/dateformat/dateformat.c2
-rw-r--r--ext/intl/dateformat/dateformat.h2
-rw-r--r--ext/intl/dateformat/dateformat_attr.c2
-rw-r--r--ext/intl/dateformat/dateformat_attr.h2
-rw-r--r--ext/intl/dateformat/dateformat_attrcpp.cpp2
-rw-r--r--ext/intl/dateformat/dateformat_attrcpp.h2
-rw-r--r--ext/intl/dateformat/dateformat_class.c2
-rw-r--r--ext/intl/dateformat/dateformat_class.h2
-rw-r--r--ext/intl/dateformat/dateformat_create.cpp2
-rw-r--r--ext/intl/dateformat/dateformat_create.h2
-rw-r--r--ext/intl/dateformat/dateformat_data.c2
-rw-r--r--ext/intl/dateformat/dateformat_data.h2
-rw-r--r--ext/intl/dateformat/dateformat_format.c2
-rw-r--r--ext/intl/dateformat/dateformat_format.h2
-rw-r--r--ext/intl/dateformat/dateformat_format_object.cpp2
-rw-r--r--ext/intl/dateformat/dateformat_format_object.h2
-rw-r--r--ext/intl/dateformat/dateformat_helpers.cpp2
-rw-r--r--ext/intl/dateformat/dateformat_helpers.h2
-rw-r--r--ext/intl/dateformat/dateformat_parse.c2
-rw-r--r--ext/intl/dateformat/dateformat_parse.h2
-rw-r--r--ext/intl/formatter/formatter.c2
-rw-r--r--ext/intl/formatter/formatter.h2
-rw-r--r--ext/intl/formatter/formatter_attr.c2
-rw-r--r--ext/intl/formatter/formatter_attr.h2
-rw-r--r--ext/intl/formatter/formatter_class.c2
-rw-r--r--ext/intl/formatter/formatter_class.h2
-rw-r--r--ext/intl/formatter/formatter_data.c2
-rw-r--r--ext/intl/formatter/formatter_data.h2
-rw-r--r--ext/intl/formatter/formatter_format.c2
-rw-r--r--ext/intl/formatter/formatter_format.h2
-rw-r--r--ext/intl/formatter/formatter_main.c2
-rw-r--r--ext/intl/formatter/formatter_main.h2
-rw-r--r--ext/intl/formatter/formatter_parse.c2
-rw-r--r--ext/intl/formatter/formatter_parse.h2
-rw-r--r--ext/intl/grapheme/grapheme.h2
-rw-r--r--ext/intl/grapheme/grapheme_util.c2
-rw-r--r--ext/intl/grapheme/grapheme_util.h2
-rw-r--r--ext/intl/idn/idn.c4
-rw-r--r--ext/intl/idn/idn.h2
-rw-r--r--ext/intl/intl_common.h2
-rw-r--r--ext/intl/intl_convert.c2
-rw-r--r--ext/intl/intl_convert.h2
-rw-r--r--ext/intl/intl_convertcpp.cpp2
-rw-r--r--ext/intl/intl_convertcpp.h2
-rw-r--r--ext/intl/intl_cppshims.h2
-rw-r--r--ext/intl/intl_data.h2
-rw-r--r--ext/intl/intl_error.c2
-rw-r--r--ext/intl/intl_error.h4
-rw-r--r--ext/intl/locale/locale.c2
-rw-r--r--ext/intl/locale/locale.h2
-rw-r--r--ext/intl/locale/locale_class.c2
-rw-r--r--ext/intl/locale/locale_class.h2
-rw-r--r--ext/intl/locale/locale_methods.c4
-rw-r--r--ext/intl/locale/locale_methods.h2
-rw-r--r--ext/intl/msgformat/msgformat.c2
-rw-r--r--ext/intl/msgformat/msgformat.h2
-rw-r--r--ext/intl/msgformat/msgformat_attr.c2
-rw-r--r--ext/intl/msgformat/msgformat_attr.h2
-rw-r--r--ext/intl/msgformat/msgformat_class.c2
-rw-r--r--ext/intl/msgformat/msgformat_class.h2
-rw-r--r--ext/intl/msgformat/msgformat_data.c2
-rw-r--r--ext/intl/msgformat/msgformat_data.h2
-rw-r--r--ext/intl/msgformat/msgformat_format.c2
-rw-r--r--ext/intl/msgformat/msgformat_format.h2
-rw-r--r--ext/intl/msgformat/msgformat_helpers.cpp2
-rw-r--r--ext/intl/msgformat/msgformat_helpers.h2
-rw-r--r--ext/intl/msgformat/msgformat_parse.c2
-rw-r--r--ext/intl/msgformat/msgformat_parse.h2
-rw-r--r--ext/intl/normalizer/normalizer.c2
-rw-r--r--ext/intl/normalizer/normalizer.h2
-rw-r--r--ext/intl/normalizer/normalizer_class.c2
-rw-r--r--ext/intl/normalizer/normalizer_class.h2
-rw-r--r--ext/intl/normalizer/normalizer_normalize.h2
-rw-r--r--ext/intl/php_intl.c2
-rw-r--r--ext/intl/php_intl.h2
-rw-r--r--ext/intl/resourcebundle/resourcebundle.c2
-rw-r--r--ext/intl/resourcebundle/resourcebundle.h2
-rw-r--r--ext/intl/resourcebundle/resourcebundle_class.c2
-rw-r--r--ext/intl/resourcebundle/resourcebundle_class.h2
-rw-r--r--ext/intl/resourcebundle/resourcebundle_iterator.c2
-rw-r--r--ext/intl/resourcebundle/resourcebundle_iterator.h2
-rw-r--r--ext/intl/spoofchecker/spoofchecker.c2
-rw-r--r--ext/intl/spoofchecker/spoofchecker.h2
-rw-r--r--ext/intl/spoofchecker/spoofchecker_class.c2
-rw-r--r--ext/intl/spoofchecker/spoofchecker_class.h2
-rw-r--r--ext/intl/spoofchecker/spoofchecker_create.c2
-rw-r--r--ext/intl/spoofchecker/spoofchecker_create.h2
-rw-r--r--ext/intl/spoofchecker/spoofchecker_main.c2
-rw-r--r--ext/intl/spoofchecker/spoofchecker_main.h2
-rw-r--r--ext/intl/timezone/timezone_class.cpp2
-rw-r--r--ext/intl/timezone/timezone_class.h2
-rw-r--r--ext/intl/timezone/timezone_methods.cpp2
-rw-r--r--ext/intl/timezone/timezone_methods.h2
-rw-r--r--ext/intl/transliterator/transliterator.c2
-rw-r--r--ext/intl/transliterator/transliterator.h4
-rw-r--r--ext/intl/transliterator/transliterator_class.c2
-rw-r--r--ext/intl/transliterator/transliterator_class.h2
-rw-r--r--ext/intl/transliterator/transliterator_methods.c2
-rw-r--r--ext/intl/transliterator/transliterator_methods.h2
-rw-r--r--ext/json/JSON_parser.h2
-rw-r--r--ext/json/json.c8
-rw-r--r--ext/json/json.dsp135
-rw-r--r--ext/json/php_json.h4
-rw-r--r--ext/json/utf8_decode.h2
-rw-r--r--ext/ldap/LDAP_Win32_HOWTO.txt2
-rw-r--r--ext/ldap/ldap.c25
-rw-r--r--ext/ldap/ldap.dsp288
-rw-r--r--ext/ldap/ldap.mak2
-rw-r--r--ext/ldap/php_ldap.h2
-rw-r--r--ext/libxml/libxml.c18
-rw-r--r--ext/libxml/php_libxml.h4
-rw-r--r--ext/mbstring/libmbfl/NEWS1
-rw-r--r--ext/mbstring/mb_gpc.c2
-rw-r--r--ext/mbstring/mb_gpc.h10
-rw-r--r--ext/mbstring/mbstring.c6
-rw-r--r--ext/mbstring/mbstring.dsp1112
-rw-r--r--ext/mbstring/mbstring.h2
-rw-r--r--ext/mbstring/php_mbregex.c10
-rw-r--r--ext/mbstring/php_mbregex.h2
-rw-r--r--ext/mbstring/php_unicode.c2
-rw-r--r--ext/mbstring/php_unicode.h2
-rw-r--r--ext/mbstring/tests/zend_multibyte-02.phpt3
-rw-r--r--ext/mbstring/tests/zend_multibyte-06.phpt2
-rw-r--r--ext/mbstring/tests/zend_multibyte-07.phpt3
-rw-r--r--ext/mbstring/tests/zend_multibyte-09.phpt3
-rw-r--r--ext/mcrypt/mcrypt.c6
-rw-r--r--ext/mcrypt/mcrypt.dsp117
-rw-r--r--ext/mcrypt/mcrypt_filter.c2
-rw-r--r--ext/mcrypt/php_mcrypt.h2
-rw-r--r--ext/mcrypt/php_mcrypt_filter.h2
-rw-r--r--ext/mssql/mssql.dsp117
-rw-r--r--ext/mssql/mssql_win32_howto.txt2
-rw-r--r--ext/mssql/php_mssql.c4
-rw-r--r--ext/mssql/php_mssql.h2
-rw-r--r--ext/mysql/mysql.dsp171
-rw-r--r--ext/mysql/mysql_mysqlnd.h2
-rw-r--r--ext/mysql/php_mysql.c2
-rw-r--r--ext/mysql/php_mysql.h2
-rw-r--r--ext/mysql/php_mysql_structs.h2
-rw-r--r--ext/mysqli/mysqli.c2
-rwxr-xr-xext/mysqli/mysqli.dsp120
-rw-r--r--ext/mysqli/mysqli_api.c4
-rw-r--r--ext/mysqli/mysqli_driver.c2
-rw-r--r--ext/mysqli/mysqli_embedded.c2
-rw-r--r--ext/mysqli/mysqli_exception.c2
-rw-r--r--ext/mysqli/mysqli_fe.c2
-rw-r--r--ext/mysqli/mysqli_fe.h2
-rw-r--r--ext/mysqli/mysqli_libmysql.h2
-rw-r--r--ext/mysqli/mysqli_mysqlnd.h2
-rw-r--r--ext/mysqli/mysqli_nonapi.c4
-rw-r--r--ext/mysqli/mysqli_priv.h2
-rw-r--r--ext/mysqli/mysqli_prop.c8
-rw-r--r--ext/mysqli/mysqli_report.c2
-rw-r--r--ext/mysqli/mysqli_result_iterator.c2
-rw-r--r--ext/mysqli/mysqli_warning.c4
-rw-r--r--ext/mysqli/php_mysqli.h2
-rw-r--r--ext/mysqli/php_mysqli_structs.h2
-rw-r--r--ext/mysqlnd/mysqlnd.c8
-rw-r--r--ext/mysqlnd/mysqlnd.h6
-rw-r--r--ext/mysqlnd/mysqlnd_alloc.c4
-rw-r--r--ext/mysqlnd/mysqlnd_alloc.h2
-rw-r--r--ext/mysqlnd/mysqlnd_auth.c2
-rw-r--r--ext/mysqlnd/mysqlnd_block_alloc.c2
-rw-r--r--ext/mysqlnd/mysqlnd_block_alloc.h2
-rw-r--r--ext/mysqlnd/mysqlnd_charset.c2
-rw-r--r--ext/mysqlnd/mysqlnd_charset.h2
-rw-r--r--ext/mysqlnd/mysqlnd_debug.c2
-rw-r--r--ext/mysqlnd/mysqlnd_debug.h2
-rw-r--r--ext/mysqlnd/mysqlnd_driver.c2
-rw-r--r--ext/mysqlnd/mysqlnd_enum_n_def.h2
-rw-r--r--ext/mysqlnd/mysqlnd_ext_plugin.c2
-rw-r--r--ext/mysqlnd/mysqlnd_ext_plugin.h2
-rw-r--r--ext/mysqlnd/mysqlnd_libmysql_compat.h2
-rw-r--r--ext/mysqlnd/mysqlnd_loaddata.c2
-rw-r--r--ext/mysqlnd/mysqlnd_net.c2
-rw-r--r--ext/mysqlnd/mysqlnd_net.h2
-rw-r--r--ext/mysqlnd/mysqlnd_plugin.c2
-rw-r--r--ext/mysqlnd/mysqlnd_priv.h2
-rw-r--r--ext/mysqlnd/mysqlnd_ps.c4
-rw-r--r--ext/mysqlnd/mysqlnd_ps_codec.c14
-rw-r--r--ext/mysqlnd/mysqlnd_result.c2
-rw-r--r--ext/mysqlnd/mysqlnd_result.h2
-rw-r--r--ext/mysqlnd/mysqlnd_result_meta.c2
-rw-r--r--ext/mysqlnd/mysqlnd_result_meta.h2
-rw-r--r--ext/mysqlnd/mysqlnd_reverse_api.c2
-rw-r--r--ext/mysqlnd/mysqlnd_reverse_api.h2
-rw-r--r--ext/mysqlnd/mysqlnd_statistics.c2
-rw-r--r--ext/mysqlnd/mysqlnd_statistics.h2
-rw-r--r--ext/mysqlnd/mysqlnd_structs.h40
-rw-r--r--ext/mysqlnd/mysqlnd_wireprotocol.c6
-rw-r--r--ext/mysqlnd/mysqlnd_wireprotocol.h10
-rw-r--r--ext/mysqlnd/php_mysqlnd.c4
-rw-r--r--ext/mysqlnd/php_mysqlnd.h2
-rw-r--r--ext/oci8/oci8.c88
-rw-r--r--ext/oci8/oci8.dsp133
-rw-r--r--ext/oci8/oci8_collection.c36
-rw-r--r--ext/oci8/oci8_interface.c409
-rw-r--r--ext/oci8/oci8_lob.c28
-rw-r--r--ext/oci8/oci8_statement.c194
-rw-r--r--ext/oci8/php_oci8.h2
-rw-r--r--ext/oci8/php_oci8_int.h80
-rw-r--r--ext/odbc/birdstep.c2
-rw-r--r--ext/odbc/php_birdstep.h2
-rw-r--r--ext/odbc/php_odbc.c6
-rw-r--r--ext/odbc/php_odbc.h2
-rw-r--r--ext/odbc/php_odbc_includes.h2
-rw-r--r--ext/opcache/Optimizer/block_pass.c77
-rw-r--r--ext/opcache/Optimizer/compact_literals.c4
-rw-r--r--ext/opcache/Optimizer/nop_removal.c2
-rw-r--r--ext/opcache/Optimizer/pass1_5.c33
-rw-r--r--ext/opcache/Optimizer/pass2.c3
-rw-r--r--ext/opcache/Optimizer/pass3.c2
-rw-r--r--ext/opcache/Optimizer/zend_optimizer.c85
-rw-r--r--ext/opcache/Optimizer/zend_optimizer_internal.h13
-rw-r--r--ext/opcache/ZendAccelerator.c136
-rw-r--r--ext/opcache/zend_accelerator_util_funcs.c8
-rw-r--r--ext/opcache/zend_persist.c2
-rw-r--r--ext/opcache/zend_persist_calc.c2
-rw-r--r--ext/openssl/config0.m46
-rwxr-xr-xext/openssl/openssl.c16
-rw-r--r--ext/openssl/openssl.dsp111
-rw-r--r--ext/openssl/openssl.mak2
-rw-r--r--ext/openssl/php_openssl.h2
-rw-r--r--ext/openssl/tests/bug65729.pem42
-rw-r--r--ext/openssl/xp_ssl.c39
-rw-r--r--ext/pcntl/pcntl.c2
-rw-r--r--ext/pcntl/php_pcntl.h2
-rw-r--r--ext/pcntl/php_signal.c2
-rw-r--r--ext/pcntl/php_signal.h2
-rw-r--r--ext/pcre/php_pcre.c8
-rw-r--r--ext/pcre/php_pcre.h2
-rw-r--r--ext/pdo/pdo.c2
-rw-r--r--ext/pdo/pdo_dbh.c8
-rw-r--r--ext/pdo/pdo_sql_parser.c4
-rw-r--r--ext/pdo/pdo_sql_parser.re2
-rw-r--r--ext/pdo/pdo_sqlstate.c2
-rw-r--r--ext/pdo/pdo_stmt.c6
-rw-r--r--ext/pdo/php_pdo.h2
-rw-r--r--ext/pdo/php_pdo_driver.h17
-rw-r--r--ext/pdo/php_pdo_error.h2
-rw-r--r--ext/pdo/php_pdo_int.h2
-rw-r--r--ext/pdo_dblib/dblib_driver.c2
-rw-r--r--ext/pdo_dblib/dblib_stmt.c2
-rw-r--r--ext/pdo_dblib/pdo_dblib.c2
-rw-r--r--ext/pdo_dblib/php_pdo_dblib.h2
-rw-r--r--ext/pdo_dblib/php_pdo_dblib_int.h2
-rw-r--r--ext/pdo_firebird/firebird_driver.c2
-rw-r--r--ext/pdo_firebird/firebird_statement.c2
-rw-r--r--ext/pdo_firebird/pdo_firebird.c2
-rw-r--r--ext/pdo_firebird/php_pdo_firebird.h2
-rw-r--r--ext/pdo_firebird/php_pdo_firebird_int.h2
-rw-r--r--ext/pdo_mysql/mysql_driver.c2
-rw-r--r--ext/pdo_mysql/mysql_statement.c2
-rw-r--r--ext/pdo_mysql/pdo_mysql.c2
-rw-r--r--ext/pdo_mysql/php_pdo_mysql.h2
-rw-r--r--ext/pdo_mysql/php_pdo_mysql_int.h2
-rw-r--r--ext/pdo_oci/oci_driver.c2
-rw-r--r--ext/pdo_oci/oci_statement.c2
-rw-r--r--ext/pdo_oci/pdo_oci.c2
-rw-r--r--ext/pdo_oci/php_pdo_oci.h2
-rw-r--r--ext/pdo_oci/php_pdo_oci_int.h2
-rw-r--r--ext/pdo_odbc/odbc_driver.c2
-rw-r--r--ext/pdo_odbc/odbc_stmt.c2
-rw-r--r--ext/pdo_odbc/pdo_odbc.c2
-rw-r--r--ext/pdo_odbc/php_pdo_odbc.h2
-rw-r--r--ext/pdo_odbc/php_pdo_odbc_int.h2
-rw-r--r--ext/pdo_pgsql/pdo_pgsql.c2
-rw-r--r--ext/pdo_pgsql/pgsql_driver.c2
-rw-r--r--ext/pdo_pgsql/pgsql_statement.c2
-rw-r--r--ext/pdo_pgsql/php_pdo_pgsql.h2
-rw-r--r--ext/pdo_pgsql/php_pdo_pgsql_int.h2
-rw-r--r--ext/pdo_pgsql/tests/getnotify.phpt6
-rw-r--r--ext/pdo_sqlite/pdo_sqlite.c2
-rw-r--r--ext/pdo_sqlite/php_pdo_sqlite.h2
-rw-r--r--ext/pdo_sqlite/php_pdo_sqlite_int.h2
-rw-r--r--ext/pdo_sqlite/sqlite_driver.c2
-rw-r--r--ext/pdo_sqlite/sqlite_statement.c2
-rw-r--r--ext/pgsql/pgsql.c32
-rw-r--r--ext/pgsql/pgsql.dsp167
-rw-r--r--ext/pgsql/php_pgsql.h2
-rw-r--r--ext/phar/phar.c4
-rw-r--r--ext/phar/phar_internal.h2
-rwxr-xr-xext/phar/phar_object.c17
-rw-r--r--ext/phar/tar.c2
-rw-r--r--ext/phar/zip.c4
-rw-r--r--ext/posix/php_posix.h2
-rw-r--r--ext/posix/posix.c2
-rw-r--r--ext/pspell/php_pspell.h2
-rw-r--r--ext/pspell/pspell.c2
-rw-r--r--ext/pspell/pspell.dsp112
-rw-r--r--ext/readline/php_readline.h2
-rw-r--r--ext/readline/readline.c2
-rw-r--r--ext/readline/readline_cli.c4
-rw-r--r--ext/readline/readline_cli.h4
-rw-r--r--ext/recode/php_recode.h2
-rw-r--r--ext/recode/recode.c2
-rw-r--r--ext/reflection/php_reflection.c98
-rw-r--r--ext/reflection/php_reflection.h2
-rw-r--r--ext/session/mod_files.c4
-rw-r--r--ext/session/mod_files.h2
-rw-r--r--ext/session/mod_mm.c2
-rw-r--r--ext/session/mod_mm.h2
-rw-r--r--ext/session/mod_user.c4
-rw-r--r--ext/session/mod_user.h2
-rw-r--r--ext/session/mod_user_class.c2
-rw-r--r--ext/session/php_session.h2
-rw-r--r--ext/session/session.c7
-rw-r--r--ext/shmop/php_shmop.h2
-rw-r--r--ext/shmop/shmop.dsp107
-rw-r--r--ext/simplexml/php_simplexml.h2
-rw-r--r--ext/simplexml/php_simplexml_exports.h2
-rw-r--r--ext/simplexml/simplexml.c2
-rw-r--r--ext/simplexml/simplexml.dsp111
-rw-r--r--ext/simplexml/sxe.c2
-rw-r--r--ext/simplexml/sxe.h2
-rw-r--r--ext/skeleton/skeleton.dsp113
-rw-r--r--ext/skeleton/tests/001.phpt2
-rw-r--r--ext/snmp/php_snmp.h2
-rw-r--r--ext/snmp/snmp.c2
-rw-r--r--ext/snmp/snmp.dsp109
-rw-r--r--ext/soap/php_encoding.c10
-rw-r--r--ext/soap/php_encoding.h2
-rw-r--r--ext/soap/php_http.c4
-rw-r--r--ext/soap/php_http.h2
-rw-r--r--ext/soap/php_packet_soap.c2
-rw-r--r--ext/soap/php_packet_soap.h2
-rw-r--r--ext/soap/php_schema.c2
-rw-r--r--ext/soap/php_schema.h2
-rw-r--r--ext/soap/php_sdl.c10
-rw-r--r--ext/soap/php_sdl.h2
-rw-r--r--ext/soap/php_soap.dsp156
-rw-r--r--ext/soap/php_soap.h4
-rw-r--r--ext/soap/php_xml.c2
-rw-r--r--ext/soap/php_xml.h2
-rw-r--r--ext/soap/soap.c19
-rw-r--r--ext/sockets/conversions.c10
-rw-r--r--ext/sockets/multicast.c2
-rw-r--r--ext/sockets/multicast.h2
-rw-r--r--ext/sockets/php_sockets.h2
-rw-r--r--ext/sockets/sendrecvmsg.c2
-rw-r--r--ext/sockets/sockets.c10
-rw-r--r--ext/sockets/sockets.dsp117
-rw-r--r--ext/sockets/unix_socket_constants.h2
-rw-r--r--ext/sockets/win32_socket_constants.h2
-rw-r--r--ext/sockets/windows_common.h2
-rw-r--r--ext/spl/php_spl.c4
-rw-r--r--ext/spl/php_spl.h4
-rw-r--r--ext/spl/spl_array.c4
-rw-r--r--ext/spl/spl_array.h2
-rw-r--r--ext/spl/spl_directory.c20
-rw-r--r--ext/spl/spl_directory.h2
-rw-r--r--ext/spl/spl_dllist.c6
-rw-r--r--ext/spl/spl_dllist.h2
-rw-r--r--ext/spl/spl_engine.c2
-rw-r--r--ext/spl/spl_engine.h2
-rw-r--r--ext/spl/spl_exceptions.c2
-rw-r--r--ext/spl/spl_exceptions.h2
-rw-r--r--ext/spl/spl_fixedarray.c2
-rw-r--r--ext/spl/spl_fixedarray.h2
-rw-r--r--ext/spl/spl_functions.c5
-rw-r--r--ext/spl/spl_functions.h2
-rw-r--r--ext/spl/spl_heap.c2
-rw-r--r--ext/spl/spl_heap.h2
-rw-r--r--ext/spl/spl_iterators.c6
-rw-r--r--ext/spl/spl_iterators.h10
-rw-r--r--ext/spl/spl_observer.c4
-rw-r--r--ext/spl/spl_observer.h2
-rw-r--r--ext/sqlite3/php_sqlite3.h2
-rw-r--r--ext/sqlite3/php_sqlite3_structs.h2
-rw-r--r--ext/sqlite3/sqlite3.c2
-rw-r--r--ext/standard/array.c39
-rw-r--r--ext/standard/assert.c4
-rw-r--r--ext/standard/base64.c6
-rw-r--r--ext/standard/base64.h2
-rw-r--r--ext/standard/basic_functions.c33
-rw-r--r--ext/standard/basic_functions.h6
-rw-r--r--ext/standard/browscap.c14
-rw-r--r--ext/standard/crc32.c2
-rw-r--r--ext/standard/crc32.h2
-rw-r--r--ext/standard/credits.c2
-rw-r--r--ext/standard/credits.h2
-rw-r--r--ext/standard/credits_ext.h6
-rw-r--r--ext/standard/credits_sapi.h6
-rw-r--r--ext/standard/crypt.c6
-rw-r--r--ext/standard/crypt_sha256.c17
-rw-r--r--ext/standard/crypt_sha512.c16
-rw-r--r--ext/standard/css.c2
-rw-r--r--ext/standard/css.h2
-rw-r--r--ext/standard/cyr_convert.c11
-rw-r--r--ext/standard/cyr_convert.h2
-rw-r--r--ext/standard/datetime.c2
-rw-r--r--ext/standard/datetime.h2
-rw-r--r--ext/standard/dir.c2
-rw-r--r--ext/standard/dl.c2
-rw-r--r--ext/standard/dl.h2
-rw-r--r--ext/standard/dns.c4
-rw-r--r--ext/standard/dns_win32.c2
-rw-r--r--ext/standard/exec.c2
-rw-r--r--ext/standard/exec.h2
-rw-r--r--ext/standard/file.c8
-rw-r--r--ext/standard/file.h2
-rw-r--r--ext/standard/filestat.c20
-rw-r--r--ext/standard/filters.c28
-rw-r--r--ext/standard/flock_compat.c2
-rw-r--r--ext/standard/flock_compat.h2
-rw-r--r--ext/standard/formatted_print.c4
-rw-r--r--ext/standard/fsock.c2
-rw-r--r--ext/standard/fsock.h2
-rw-r--r--ext/standard/ftok.c2
-rw-r--r--ext/standard/ftp_fopen_wrapper.c4
-rw-r--r--ext/standard/head.c2
-rw-r--r--ext/standard/head.h2
-rw-r--r--ext/standard/html.c6
-rw-r--r--ext/standard/html.h2
-rw-r--r--ext/standard/html_tables.h267
-rw-r--r--ext/standard/html_tables/html_table_gen.php23
-rw-r--r--ext/standard/http.c24
-rw-r--r--ext/standard/http_fopen_wrapper.c8
-rw-r--r--ext/standard/image.c8
-rw-r--r--ext/standard/incomplete_class.c2
-rw-r--r--ext/standard/info.c6
-rw-r--r--ext/standard/info.h2
-rw-r--r--ext/standard/iptc.c6
-rw-r--r--ext/standard/lcg.c2
-rw-r--r--ext/standard/levenshtein.c2
-rw-r--r--ext/standard/link.c2
-rw-r--r--ext/standard/link_win32.c2
-rw-r--r--ext/standard/mail.c2
-rw-r--r--ext/standard/math.c4
-rw-r--r--ext/standard/md5.c20
-rw-r--r--ext/standard/md5.h2
-rw-r--r--ext/standard/metaphone.c2
-rw-r--r--ext/standard/microtime.c2
-rw-r--r--ext/standard/microtime.h2
-rw-r--r--ext/standard/pack.c2
-rw-r--r--ext/standard/pack.h2
-rw-r--r--ext/standard/pageinfo.c2
-rw-r--r--ext/standard/pageinfo.h2
-rw-r--r--ext/standard/password.c18
-rw-r--r--ext/standard/php_array.h2
-rw-r--r--ext/standard/php_assert.h2
-rw-r--r--ext/standard/php_browscap.h2
-rw-r--r--ext/standard/php_crypt.h2
-rw-r--r--ext/standard/php_crypt_r.c6
-rw-r--r--ext/standard/php_crypt_r.h2
-rw-r--r--ext/standard/php_dir.h2
-rw-r--r--ext/standard/php_dns.h2
-rw-r--r--ext/standard/php_ext_syslog.h2
-rw-r--r--ext/standard/php_filestat.h2
-rw-r--r--ext/standard/php_fopen_wrapper.c2
-rw-r--r--ext/standard/php_fopen_wrappers.h2
-rw-r--r--ext/standard/php_ftok.h2
-rw-r--r--ext/standard/php_http.h4
-rw-r--r--ext/standard/php_image.h2
-rw-r--r--ext/standard/php_incomplete_class.h2
-rw-r--r--ext/standard/php_iptc.h2
-rw-r--r--ext/standard/php_lcg.h2
-rw-r--r--ext/standard/php_link.h2
-rw-r--r--ext/standard/php_mail.h2
-rw-r--r--ext/standard/php_math.h2
-rw-r--r--ext/standard/php_metaphone.h2
-rw-r--r--ext/standard/php_password.h2
-rw-r--r--ext/standard/php_rand.h2
-rw-r--r--ext/standard/php_smart_str.h175
-rw-r--r--ext/standard/php_smart_str_public.h31
-rw-r--r--ext/standard/php_smart_string.h26
-rw-r--r--ext/standard/php_smart_string_public.h2
-rw-r--r--ext/standard/php_standard.h2
-rw-r--r--ext/standard/php_string.h2
-rw-r--r--ext/standard/php_type.h2
-rw-r--r--ext/standard/php_uuencode.h2
-rw-r--r--ext/standard/php_var.h113
-rw-r--r--ext/standard/php_versioning.h2
-rw-r--r--ext/standard/proc_open.c2
-rw-r--r--ext/standard/proc_open.h2
-rw-r--r--ext/standard/quot_print.c2
-rw-r--r--ext/standard/quot_print.h2
-rw-r--r--ext/standard/rand.c2
-rw-r--r--ext/standard/scanf.c2
-rw-r--r--ext/standard/scanf.h2
-rw-r--r--ext/standard/sha1.c16
-rw-r--r--ext/standard/sha1.h2
-rw-r--r--ext/standard/soundex.c2
-rw-r--r--ext/standard/streamsfuncs.c2
-rw-r--r--ext/standard/streamsfuncs.h2
-rw-r--r--ext/standard/string.c77
-rw-r--r--ext/standard/strnatcmp.c5
-rw-r--r--ext/standard/syslog.c2
-rw-r--r--ext/standard/tests/file/bug41655_1-win32.phpt22
-rw-r--r--ext/standard/tests/file/bug41655_1.phpt8
-rw-r--r--ext/standard/tests/file/bug65701.phpt4
-rw-r--r--ext/standard/tests/file/file_put_contents_variation5.phpt1
-rw-r--r--ext/standard/tests/serialize/counting_of_references.phpt14
-rw-r--r--ext/standard/tests/streams/proc_open_bug51800.phpt95
-rw-r--r--ext/standard/tests/streams/proc_open_bug51800_right.phpt78
-rw-r--r--ext/standard/tests/streams/proc_open_bug51800_right2.phpt84
-rw-r--r--ext/standard/tests/streams/proc_open_bug60120.phpt71
-rw-r--r--ext/standard/tests/streams/proc_open_bug64438.phpt70
-rw-r--r--ext/standard/tests/strings/setlocale_variation2.phpt4
-rw-r--r--ext/standard/tests/strings/strnatcasecmp_variation1.phpt4
-rw-r--r--ext/standard/type.c2
-rw-r--r--ext/standard/uniqid.c2
-rw-r--r--ext/standard/uniqid.h2
-rw-r--r--ext/standard/url.c2
-rw-r--r--ext/standard/url.h2
-rw-r--r--ext/standard/url_scanner_ex.c24
-rw-r--r--ext/standard/url_scanner_ex.h4
-rw-r--r--ext/standard/url_scanner_ex.re24
-rw-r--r--ext/standard/user_filters.c2
-rw-r--r--ext/standard/uuencode.c2
-rw-r--r--ext/standard/var.c149
-rw-r--r--ext/standard/var_unserializer.c4
-rw-r--r--ext/standard/var_unserializer.re4
-rw-r--r--ext/standard/versioning.c2
-rw-r--r--ext/sybase_ct/php_sybase_ct.c2
-rw-r--r--ext/sybase_ct/php_sybase_ct.h2
-rw-r--r--ext/sybase_ct/sybase_ct.dsp114
-rw-r--r--ext/sysvmsg/php_sysvmsg.h2
-rw-r--r--ext/sysvmsg/sysvmsg.c4
-rw-r--r--ext/sysvsem/php_sysvsem.h2
-rw-r--r--ext/sysvsem/sysvsem.c20
-rw-r--r--ext/sysvsem/tests/nowait.phpt103
-rw-r--r--ext/sysvsem/tests/sysv.phpt4
-rw-r--r--ext/sysvshm/php_sysvshm.h2
-rw-r--r--ext/sysvshm/sysvshm.c4
-rw-r--r--ext/tidy/examples/cleanhtml.php4
-rw-r--r--ext/tidy/examples/cleanhtml5.php4
-rw-r--r--ext/tidy/php_tidy.h2
-rw-r--r--ext/tidy/tidy.c2
-rwxr-xr-xext/tidy/tidy.dsp108
-rw-r--r--ext/tokenizer/php_tokenizer.h2
-rw-r--r--ext/tokenizer/tokenizer.c4
-rw-r--r--ext/tokenizer/tokenizer.dsp108
-rw-r--r--ext/tokenizer/tokenizer_data.c2
-rwxr-xr-xext/tokenizer/tokenizer_data_gen.sh2
-rw-r--r--ext/wddx/php_wddx.h2
-rw-r--r--ext/wddx/php_wddx_api.h4
-rw-r--r--ext/wddx/wddx.c17
-rw-r--r--ext/xml/compat.c2
-rw-r--r--ext/xml/expat_compat.h2
-rw-r--r--ext/xml/php_xml.h6
-rw-r--r--ext/xml/xml.c10
-rw-r--r--ext/xml/xml.mak2
-rw-r--r--ext/xmlreader/README2
-rw-r--r--ext/xmlreader/php_xmlreader.c2
-rw-r--r--ext/xmlreader/php_xmlreader.h2
-rw-r--r--ext/xmlreader/xmlreader.dsp114
-rw-r--r--ext/xmlrpc/php_xmlrpc.h2
-rw-r--r--ext/xmlrpc/xmlrpc-epi-php.c6
-rw-r--r--ext/xmlrpc/xmlrpc.dsp211
-rw-r--r--ext/xmlwriter/TODO2
-rw-r--r--ext/xmlwriter/php_xmlwriter.c2
-rw-r--r--ext/xmlwriter/php_xmlwriter.h2
-rw-r--r--ext/xmlwriter/xmlwriter.dsp113
-rw-r--r--ext/xsl/php_xsl.c2
-rw-r--r--ext/xsl/php_xsl.h2
-rw-r--r--ext/xsl/xsl.dsp120
-rw-r--r--ext/xsl/xsl_fe.h2
-rw-r--r--ext/xsl/xsltprocessor.c4
-rw-r--r--ext/zip/lib/config.h2
-rw-r--r--ext/zip/lib/zip_set_name.c2
-rw-r--r--ext/zip/php_zip.c12
-rw-r--r--ext/zip/php_zip.h4
-rw-r--r--ext/zip/zip_stream.c2
-rw-r--r--ext/zlib/php_zlib.h4
-rw-r--r--ext/zlib/zlib.c2
-rw-r--r--ext/zlib/zlib.dsp121
-rw-r--r--ext/zlib/zlib_filter.c4
-rw-r--r--ext/zlib/zlib_fopen_wrapper.c8
-rw-r--r--ext/zlib/zlib_win32_howto.txt2
817 files changed, 3431 insertions, 9792 deletions
diff --git a/ext/bcmath/bcmath.c b/ext/bcmath/bcmath.c
index 53d85a541b..7ef30cad5e 100644
--- a/ext/bcmath/bcmath.c
+++ b/ext/bcmath/bcmath.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/bcmath/php_bcmath.h b/ext/bcmath/php_bcmath.h
index df16410004..12098cff89 100644
--- a/ext/bcmath/php_bcmath.h
+++ b/ext/bcmath/php_bcmath.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/bz2/bz2.c b/ext/bz2/bz2.c
index e04a75c1b5..6e6f2a95c3 100644
--- a/ext/bz2/bz2.c
+++ b/ext/bz2/bz2.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -359,12 +359,6 @@ static PHP_FUNCTION(bzread)
}
data = zend_string_alloc(len, 0);
data->len = php_stream_read(stream, data->val, data->len);
-
- if (data->len < 0) {
- zend_string_free(data);
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "could not read valid bz2 data from stream");
- RETURN_FALSE;
- }
data->val[data->len] = '\0';
RETURN_STR(data);
diff --git a/ext/bz2/bz2.dsp b/ext/bz2/bz2.dsp
deleted file mode 100644
index a054c522a7..0000000000
--- a/ext/bz2/bz2.dsp
+++ /dev/null
@@ -1,112 +0,0 @@
-# Microsoft Developer Studio Project File - Name="bz2" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=bz2 - Win32 Debug_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "bz2.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "bz2.mak" CFG="bz2 - Win32 Debug_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "bz2 - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "bz2 - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "bz2 - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MD /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "BZ2_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\..\php_build\includes" /D ZEND_DEBUG=0 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "COMPILE_DL_BZ2" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_BZ2=1 /D "PHP_BZ2_EXPORTS" /FR /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "NDEBUG"
-# ADD RSC /l 0x407 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 libbz2.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_bz2.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline" /libpath:"..\..\..\php_build\release"
-
-!ELSEIF "$(CFG)" == "bz2 - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "BZ2_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\..\php_build\includes" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "COMPILE_DL_BZ2" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_BZ2=1 /D "PHP_BZ2_EXPORTS" /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "_DEBUG"
-# ADD RSC /l 0x407 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 php5ts_debug.lib libbz2.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_bz2.dll" /pdbtype:sept /libpath:"..\..\Debug_TS" /libpath:"..\..\..\php_build\release"
-
-!ENDIF
-
-# Begin Target
-
-# Name "bz2 - Win32 Release_TS"
-# Name "bz2 - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\bz2.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\bz2_filter.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_bz2.h
-# End Source File
-# End Group
-# End Target
-# End Project
diff --git a/ext/bz2/bz2_filter.c b/ext/bz2/bz2_filter.c
index b19b46eb57..1c1d6ccfb6 100644
--- a/ext/bz2/bz2_filter.c
+++ b/ext/bz2/bz2_filter.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -34,17 +34,17 @@ enum strm_status {
};
typedef struct _php_bz2_filter_data {
- int persistent;
bz_stream strm;
char *inbuf;
- size_t inbuf_len;
char *outbuf;
+ size_t inbuf_len;
size_t outbuf_len;
- /* Decompress options */
- enum strm_status status;
- unsigned int small_footprint : 1;
- unsigned int expect_concatenated : 1;
+ enum strm_status status; /* Decompress option */
+ unsigned int small_footprint : 1; /* Decompress option */
+ unsigned int expect_concatenated : 1; /* Decompress option */
+
+ int persistent;
} php_bz2_filter_data;
/* }}} */
diff --git a/ext/bz2/php_bz2.h b/ext/bz2/php_bz2.h
index ceb151b9e4..6e90e8d67f 100644
--- a/ext/bz2/php_bz2.h
+++ b/ext/bz2/php_bz2.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/calendar/cal_unix.c b/ext/calendar/cal_unix.c
index 31367c66e0..3dd16ce45b 100644
--- a/ext/calendar/cal_unix.c
+++ b/ext/calendar/cal_unix.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/calendar/calendar.c b/ext/calendar/calendar.c
index 173cf076e1..50385482a7 100644
--- a/ext/calendar/calendar.c
+++ b/ext/calendar/calendar.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/calendar/easter.c b/ext/calendar/easter.c
index d2b36f981a..b6dc135d33 100644
--- a/ext/calendar/easter.c
+++ b/ext/calendar/easter.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/com_dotnet/com_com.c b/ext/com_dotnet/com_com.c
index 6731ea74aa..5f0b8ff697 100644
--- a/ext/com_dotnet/com_com.c
+++ b/ext/com_dotnet/com_com.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -464,7 +464,7 @@ HRESULT php_com_get_id_of_name(php_com_dotnet_object *obj, char *name,
}
/* the core of COM */
-int php_com_do_invoke_byref(php_com_dotnet_object *obj, char *name, int namelen,
+int php_com_do_invoke_byref(php_com_dotnet_object *obj, zend_internal_function *f,
WORD flags, VARIANT *v, int nargs, zval *args TSRMLS_DC)
{
DISPID dispid, altdispid;
@@ -472,20 +472,19 @@ int php_com_do_invoke_byref(php_com_dotnet_object *obj, char *name, int namelen,
HRESULT hr;
VARIANT *vargs = NULL, *byref_vals = NULL;
int i, byref_count = 0, j;
- zend_internal_function *f = (zend_internal_function*)EG(current_execute_data)->func;
/* assumption: that the active function (f) is the function we generated for the engine */
if (!f || f->arg_info == NULL) {
f = NULL;
}
- hr = php_com_get_id_of_name(obj, name, namelen, &dispid TSRMLS_CC);
+ hr = php_com_get_id_of_name(obj, f->function_name->val, f->function_name->len, &dispid TSRMLS_CC);
if (FAILED(hr)) {
char *winerr = NULL;
char *msg = NULL;
winerr = php_win32_error_to_msg(hr);
- spprintf(&msg, 0, "Unable to lookup `%s': %s", name, winerr);
+ spprintf(&msg, 0, "Unable to lookup `%s': %s", f->function_name->val, winerr);
LocalFree(winerr);
php_com_throw_exception(hr, msg TSRMLS_CC);
efree(msg);
diff --git a/ext/com_dotnet/com_dotnet.c b/ext/com_dotnet/com_dotnet.c
index eb13ba8ccd..ae2c6ee2f0 100644
--- a/ext/com_dotnet/com_dotnet.c
+++ b/ext/com_dotnet/com_dotnet.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/com_dotnet/com_extension.c b/ext/com_dotnet/com_extension.c
index fd2f0a6d70..f66119842e 100644
--- a/ext/com_dotnet/com_extension.c
+++ b/ext/com_dotnet/com_extension.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/com_dotnet/com_handlers.c b/ext/com_dotnet/com_handlers.c
index 3dec630721..74a3920e34 100644
--- a/ext/com_dotnet/com_handlers.c
+++ b/ext/com_dotnet/com_handlers.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -250,7 +250,7 @@ static PHP_FUNCTION(com_method_handler)
zval *object = getThis();
Z_OBJ_HANDLER_P(object, call_method)(
- ((zend_internal_function*)EG(current_execute_data)->func)->function_name,
+ ((zend_internal_function*)EX(func))->function_name,
Z_OBJ_P(object),
INTERNAL_FUNCTION_PARAM_PASSTHRU);
}
@@ -378,7 +378,7 @@ static int com_call_method(zend_string *method, zend_object *object, INTERNAL_FU
VariantInit(&v);
- if (SUCCESS == php_com_do_invoke_byref(obj, method->val, method->len, DISPATCH_METHOD|DISPATCH_PROPERTYGET, &v, nargs, args TSRMLS_CC)) {
+ if (SUCCESS == php_com_do_invoke_byref(obj, (zend_internal_function*)EX(func), DISPATCH_METHOD|DISPATCH_PROPERTYGET, &v, nargs, args TSRMLS_CC)) {
php_com_zval_from_variant(return_value, &v, obj->code_page TSRMLS_CC);
ret = SUCCESS;
VariantClear(&v);
diff --git a/ext/com_dotnet/com_iterator.c b/ext/com_dotnet/com_iterator.c
index f6aa1a1980..a7614673f8 100644
--- a/ext/com_dotnet/com_iterator.c
+++ b/ext/com_dotnet/com_iterator.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/com_dotnet/com_misc.c b/ext/com_dotnet/com_misc.c
index d83aeeb188..084a720ea1 100644
--- a/ext/com_dotnet/com_misc.c
+++ b/ext/com_dotnet/com_misc.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/com_dotnet/com_olechar.c b/ext/com_dotnet/com_olechar.c
index d12120f54f..51cc7e8f1d 100644
--- a/ext/com_dotnet/com_olechar.c
+++ b/ext/com_dotnet/com_olechar.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/com_dotnet/com_persist.c b/ext/com_dotnet/com_persist.c
index a1c2f77661..eb80e760c8 100644
--- a/ext/com_dotnet/com_persist.c
+++ b/ext/com_dotnet/com_persist.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/com_dotnet/com_saproxy.c b/ext/com_dotnet/com_saproxy.c
index 2eac10f5a8..881ebfbaea 100644
--- a/ext/com_dotnet/com_saproxy.c
+++ b/ext/com_dotnet/com_saproxy.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/com_dotnet/com_typeinfo.c b/ext/com_dotnet/com_typeinfo.c
index eefa28dd3a..33b1c65c9c 100644
--- a/ext/com_dotnet/com_typeinfo.c
+++ b/ext/com_dotnet/com_typeinfo.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/com_dotnet/com_variant.c b/ext/com_dotnet/com_variant.c
index 36b6e82116..dbd5529f6d 100644
--- a/ext/com_dotnet/com_variant.c
+++ b/ext/com_dotnet/com_variant.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/com_dotnet/com_wrapper.c b/ext/com_dotnet/com_wrapper.c
index 409b8f9956..6112dfb4bf 100644
--- a/ext/com_dotnet/com_wrapper.c
+++ b/ext/com_dotnet/com_wrapper.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -482,7 +482,7 @@ static void generate_dispids(php_dispatchex *disp TSRMLS_DC)
}
/* add the mappings */
- ZVAL_STR(&tmp2, zend_string_copy(name));
+ ZVAL_STR_COPY(&tmp2, name);
pid = zend_hash_next_free_element(disp->dispid_to_name);
zend_hash_index_update(disp->dispid_to_name, pid, &tmp2);
@@ -517,7 +517,7 @@ static void generate_dispids(php_dispatchex *disp TSRMLS_DC)
}
/* add the mappings */
- ZVAL_STR(&tmp2, zend_string_copy(name));
+ ZVAL_STR_COPY(&tmp2, name);
pid = zend_hash_next_free_element(disp->dispid_to_name);
zend_hash_index_update(disp->dispid_to_name, pid, &tmp2);
diff --git a/ext/com_dotnet/php_com_dotnet.h b/ext/com_dotnet/php_com_dotnet.h
index 51f621bd5f..cb60083289 100644
--- a/ext/com_dotnet/php_com_dotnet.h
+++ b/ext/com_dotnet/php_com_dotnet.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/com_dotnet/php_com_dotnet_internal.h b/ext/com_dotnet/php_com_dotnet_internal.h
index f153883006..e79e6f586d 100644
--- a/ext/com_dotnet/php_com_dotnet_internal.h
+++ b/ext/com_dotnet/php_com_dotnet_internal.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -104,12 +104,12 @@ PHP_FUNCTION(com_get_active_object);
HRESULT php_com_invoke_helper(php_com_dotnet_object *obj, DISPID id_member,
WORD flags, DISPPARAMS *disp_params, VARIANT *v, int silent, int allow_noarg TSRMLS_DC);
HRESULT php_com_get_id_of_name(php_com_dotnet_object *obj, char *name,
- int namelen, DISPID *dispid TSRMLS_DC);
+ size_t namelen, DISPID *dispid TSRMLS_DC);
int php_com_do_invoke_by_id(php_com_dotnet_object *obj, DISPID dispid,
WORD flags, VARIANT *v, int nargs, zval *args, int silent, int allow_noarg TSRMLS_DC);
int php_com_do_invoke(php_com_dotnet_object *obj, char *name, int namelen,
WORD flags, VARIANT *v, int nargs, zval *args, int allow_noarg TSRMLS_DC);
-int php_com_do_invoke_byref(php_com_dotnet_object *obj, char *name, int namelen,
+int php_com_do_invoke_byref(php_com_dotnet_object *obj, zend_internal_function *f,
WORD flags, VARIANT *v, int nargs, zval *args TSRMLS_DC);
/* com_wrapper.c */
diff --git a/ext/ctype/ctype.c b/ext/ctype/ctype.c
index 8f116b86d3..41d5559c67 100644
--- a/ext/ctype/ctype.c
+++ b/ext/ctype/ctype.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/ctype/ctype.dsp b/ext/ctype/ctype.dsp
deleted file mode 100644
index 1305c72f6a..0000000000
--- a/ext/ctype/ctype.dsp
+++ /dev/null
@@ -1,107 +0,0 @@
-# Microsoft Developer Studio Project File - Name="ctype" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=ctype - Win32 Debug_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "ctype.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "ctype.mak" CFG="ctype - Win32 Debug_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "ctype - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "ctype - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "ctype - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "CTYPE_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /D "WIN32" /D "PHP_EXPORTS" /D "COMPILE_DL_CTYPE" /D ZTS=1 /D HAVE_CTYPE=1 /D ZEND_DEBUG=0 /D "NDEBUG" /D "_WINDOWS" /D "ZEND_WIN32" /D "PHP_WIN32" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "NDEBUG"
-# ADD RSC /l 0x407 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 php5ts.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_ctype.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-
-!ELSEIF "$(CFG)" == "ctype - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "CTYPE_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /D ZEND_DEBUG=1 /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "PHP_EXPORTS" /D "COMPILE_DL_CTYPE" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_CTYPE=1 /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "_DEBUG"
-# ADD RSC /l 0x407 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 php5ts_debug.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_ctype.dll" /pdbtype:sept /libpath:"..\..\Debug_TS"
-
-!ENDIF
-
-# Begin Target
-
-# Name "ctype - Win32 Release_TS"
-# Name "ctype - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\ctype.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_ctype.h
-# End Source File
-# End Group
-# End Target
-# End Project
diff --git a/ext/ctype/php_ctype.h b/ext/ctype/php_ctype.h
index ab5ec44ec4..fc99a58c9b 100644
--- a/ext/ctype/php_ctype.h
+++ b/ext/ctype/php_ctype.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/curl/curl.dsp b/ext/curl/curl.dsp
deleted file mode 100644
index 6524fceb89..0000000000
--- a/ext/curl/curl.dsp
+++ /dev/null
@@ -1,190 +0,0 @@
-# Microsoft Developer Studio Project File - Name="curl" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=curl - Win32 Release_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "curl.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "curl.mak" CFG="curl - Win32 Release_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "curl - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "curl - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "curl - Win32 Debug_TS_SSL" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "curl - Win32 Release_TS_SSL" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "curl - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\TSRM" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "COMPILE_DL_CURL" /D ZTS=1 /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\main" /I "..\..\..\php_build\curl\include" /D "WIN32" /D "CURL_EXPORTS" /D "COMPILE_DL_CURL" /D ZTS=1 /D HAVE_CURL=1 /D ZEND_DEBUG=0 /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ZEND_WIN32" /D "PHP_WIN32" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib /nologo /dll /machine:I386
-# ADD LINK32 php5ts.lib libcurl.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib /nologo /dll /machine:I386 /nodefaultlib:"MSVCRT" /out:"..\..\Release_TS/php_curl.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline" /libpath:"..\..\..\php_build\curl\lib"
-# SUBTRACT LINK32 /pdb:none
-
-!ELSEIF "$(CFG)" == "curl - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "COMPILE_DL_CURL" /D ZTS=1 /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /GX /ZI /Od /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\main" /I "..\..\..\php_build\curl\include" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "CURL_EXPORTS" /D "COMPILE_DL_CURL" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_CURL=1 /FR /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib /nologo /dll /machine:I386
-# ADD LINK32 php5ts_debug.lib libcurl.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib wsock32.lib /nologo /dll /incremental:yes /debug /machine:I386 /nodefaultlib:"MSVCRTD" /out:"..\..\Debug_TS/php_curl.dll" /libpath:"..\..\Debug_TS" /libpath:"..\..\..\php_build\curl\lib"
-# SUBTRACT LINK32 /pdb:none
-
-!ELSEIF "$(CFG)" == "curl - Win32 Debug_TS_SSL"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "curl___Win32_Debug_TS_SSL"
-# PROP BASE Intermediate_Dir "curl___Win32_Debug_TS_SSL"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Debug_TS_SSL"
-# PROP Intermediate_Dir "Debug_TS_SSL"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MDd /W3 /GX /ZI /Od /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\main" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "CURL_EXPORTS" /D "COMPILE_DL_CURL" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_CURL=1 /FR /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /GX /ZI /Od /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\main" /I "..\..\..\php_build\curl\include" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "CURL_EXPORTS" /D "COMPILE_DL_CURL" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_CURL=1 /FR /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 php5ts_debug.lib libcurl.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /incremental:yes /debug /machine:I386 /nodefaultlib:"msvcrtd.lib" /out:"..\..\Debug_TS/php_curl.dll" /libpath:"..\..\Debug_TS"
-# SUBTRACT BASE LINK32 /pdb:none
-# ADD LINK32 php5ts_debug.lib libcurl.lib ssleay32.lib libeay32.lib msvcrt.lib ws2_32.lib winmm.lib zlib.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib /nologo /dll /incremental:yes /debug /machine:I386 /nodefaultlib:"MSVCRTD" /out:"..\..\Debug_TS/php_curl.dll" /libpath:"..\..\Debug_TS" /libpath:"..\..\..\php_build\curl\lib"
-# SUBTRACT LINK32 /pdb:none /nodefaultlib
-
-!ELSEIF "$(CFG)" == "curl - Win32 Release_TS_SSL"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "curl___Win32_Release_TS_SSL"
-# PROP BASE Intermediate_Dir "curl___Win32_Release_TS_SSL"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS_SSL"
-# PROP Intermediate_Dir "Release_TS_SSL"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\main" /D "WIN32" /D "CURL_EXPORTS" /D "COMPILE_DL_CURL" /D ZTS=1 /D HAVE_CURL=1 /D ZEND_DEBUG=0 /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ZEND_WIN32" /D "PHP_WIN32" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\main" /I "..\..\..\php_build\curl\include" /D "WIN32" /D "CURL_EXPORTS" /D "COMPILE_DL_CURL" /D ZTS=1 /D HAVE_CURL=1 /D ZEND_DEBUG=0 /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ZEND_WIN32" /D "PHP_WIN32" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 php5ts.lib libcurl.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /nodefaultlib:"msvcrt.lib" /out:"..\..\Release_TS/php_curl.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-# SUBTRACT BASE LINK32 /pdb:none
-# ADD LINK32 php5ts.lib libcurl.lib ssleay32.lib libeay32.lib msvcrt.lib ws2_32.lib winmm.lib zlib.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib /nologo /dll /machine:I386 /nodefaultlib:"MSVCRT" /out:"..\..\Release_TS/php_curl.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline" /libpath:"..\..\..\php_build\curl\lib"
-# SUBTRACT LINK32 /pdb:none
-
-!ENDIF
-
-# Begin Target
-
-# Name "curl - Win32 Release_TS"
-# Name "curl - Win32 Debug_TS"
-# Name "curl - Win32 Debug_TS_SSL"
-# Name "curl - Win32 Release_TS_SSL"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\interface.c
-# End Source File
-
-# Begin Source File
-SOURCE=.\multi.c
-# End Source File
-
-# Begin Source File
-SOURCE=.\share.c
-# End Source File
-
-# Begin Source File
-SOURCE=.\streams.c
-# End Source File
-
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_curl.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# End Target
-# End Project
diff --git a/ext/curl/curl_file.c b/ext/curl/curl_file.c
index 8e66445fb5..6b0e5462a1 100644
--- a/ext/curl/curl_file.c
+++ b/ext/curl/curl_file.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/curl/interface.c b/ext/curl/interface.c
index d8e084796d..6caaa5258b 100644
--- a/ext/curl/interface.c
+++ b/ext/curl/interface.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -82,7 +82,7 @@
#define SMART_STR_PREALLOC 4096
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#include "ext/standard/info.h"
#include "ext/standard/file.h"
#include "ext/standard/url.h"
@@ -557,6 +557,12 @@ PHP_MINFO_FUNCTION(curl)
#if LIBCURL_VERSION_NUM >= 0x071504 /* 7.21.4 */
{"TLS-SRP", CURL_VERSION_TLSAUTH_SRP},
#endif
+#if LIBCURL_VERSION_NUM >= 0x072100 /* 7.33.0 */
+ {"HTTP2", CURL_VERSION_HTTP2},
+#endif
+#if LIBCURL_VERSION_NUM >= 0x072600 /* 7.38.0 */
+ {"GSSAPI", CURL_VERSION_GSSAPI},
+#endif
{NULL, 0}
};
@@ -1832,10 +1838,10 @@ static void _php_curl_set_default_options(php_curl *ch)
curl_easy_setopt(ch->cp, CURLOPT_MAXREDIRS, 20); /* prevent infinite redirects */
cainfo = INI_STR("openssl.cafile");
- if (!(cainfo && strlen(cainfo) > 0)) {
+ if (!(cainfo && cainfo[0] != '\0')) {
cainfo = INI_STR("curl.cainfo");
}
- if (cainfo && strlen(cainfo) > 0) {
+ if (cainfo && cainfo[0] != '\0') {
curl_easy_setopt(ch->cp, CURLOPT_CAINFO, cainfo);
}
@@ -2462,7 +2468,7 @@ static int _php_curl_setopt(php_curl *ch, zend_long option, zval *zvalue TSRMLS_
zval *current;
HashTable *postfields;
zend_string *string_key;
- ulong num_key;
+ zend_ulong num_key;
struct HttpPost *first = NULL;
struct HttpPost *last = NULL;
diff --git a/ext/curl/multi.c b/ext/curl/multi.c
index 72cfd29ca7..d9e6df2c98 100644
--- a/ext/curl/multi.c
+++ b/ext/curl/multi.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/curl/php_curl.h b/ext/curl/php_curl.h
index c75d7f80d1..ad44ae7b96 100644
--- a/ext/curl/php_curl.h
+++ b/ext/curl/php_curl.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -23,7 +23,7 @@
#define _PHP_CURL_H
#include "php.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#ifdef COMPILE_DL_CURL
#undef HAVE_CURL
diff --git a/ext/curl/share.c b/ext/curl/share.c
index 90c869df02..94694e0b2e 100644
--- a/ext/curl/share.c
+++ b/ext/curl/share.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/curl/tests/check_win_config.phpt b/ext/curl/tests/check_win_config.phpt
index 103f1cf692..3d13638f90 100644
--- a/ext/curl/tests/check_win_config.phpt
+++ b/ext/curl/tests/check_win_config.phpt
@@ -28,7 +28,7 @@ Features
AsynchDNS => Yes
CharConv => No
Debug => No
-GSS-Negotiate => Yes
+GSS-Negotiate => No
IDN => Yes
IPv6 => Yes
krb4 => No
@@ -40,6 +40,8 @@ SPNEGO => Yes
SSL => Yes
SSPI => Yes
TLS-SRP => No
+HTTP2 => No
+GSSAPI => No
Protocols => dict, file, ftp, ftps, gopher, http, https, imap, imaps, ldap, pop3, pop3s, rtsp, scp, sftp, smtp, smtps, telnet, tftp
Host => %s-pc-win32
SSL Version => OpenSSL/%s
diff --git a/ext/date/lib/astro.c b/ext/date/lib/astro.c
index 7f51c71d92..84e8a40021 100644
--- a/ext/date/lib/astro.c
+++ b/ext/date/lib/astro.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/date/lib/dow.c b/ext/date/lib/dow.c
index a77fdd7182..1739566728 100644
--- a/ext/date/lib/dow.c
+++ b/ext/date/lib/dow.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/date/lib/interval.c b/ext/date/lib/interval.c
index 86e98ea744..58a185d3be 100644
--- a/ext/date/lib/interval.c
+++ b/ext/date/lib/interval.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/date/lib/parse_date.c b/ext/date/lib/parse_date.c
index 6c4819bde8..2a615559f6 100644
--- a/ext/date/lib/parse_date.c
+++ b/ext/date/lib/parse_date.c
@@ -2,7 +2,7 @@
#line 1 "ext/date/lib/parse_date.re"
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/date/lib/parse_date.re b/ext/date/lib/parse_date.re
index c5cb15f797..cb5df16251 100644
--- a/ext/date/lib/parse_date.re
+++ b/ext/date/lib/parse_date.re
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/date/lib/parse_iso_intervals.c b/ext/date/lib/parse_iso_intervals.c
index f8a781a363..3b7580f9d1 100644
--- a/ext/date/lib/parse_iso_intervals.c
+++ b/ext/date/lib/parse_iso_intervals.c
@@ -2,7 +2,7 @@
#line 1 "ext/date/lib/parse_iso_intervals.re"
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/date/lib/parse_iso_intervals.re b/ext/date/lib/parse_iso_intervals.re
index efd822e84e..097488ec57 100644
--- a/ext/date/lib/parse_iso_intervals.re
+++ b/ext/date/lib/parse_iso_intervals.re
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/date/lib/parse_tz.c b/ext/date/lib/parse_tz.c
index e7a31dd142..a503f9e01e 100644
--- a/ext/date/lib/parse_tz.c
+++ b/ext/date/lib/parse_tz.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/date/lib/timelib.c b/ext/date/lib/timelib.c
index 716975a90f..ea88a2256a 100644
--- a/ext/date/lib/timelib.c
+++ b/ext/date/lib/timelib.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -71,10 +71,11 @@ timelib_rel_time* timelib_rel_time_clone(timelib_rel_time *rel)
void timelib_time_tz_abbr_update(timelib_time* tm, char* tz_abbr)
{
unsigned int i;
+ size_t tz_abbr_len = strlen(tz_abbr);
TIMELIB_TIME_FREE(tm->tz_abbr);
tm->tz_abbr = strdup(tz_abbr);
- for (i = 0; i < strlen(tz_abbr); i++) {
+ for (i = 0; i < tz_abbr_len; i++) {
tm->tz_abbr[i] = toupper(tz_abbr[i]);
}
}
diff --git a/ext/date/lib/timelib.h b/ext/date/lib/timelib.h
index 89c9dcbc2d..b7c49888cb 100644
--- a/ext/date/lib/timelib.h
+++ b/ext/date/lib/timelib.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/date/lib/timelib_structs.h b/ext/date/lib/timelib_structs.h
index e5780f6cca..3f9f5b07e7 100644
--- a/ext/date/lib/timelib_structs.h
+++ b/ext/date/lib/timelib_structs.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -173,10 +173,10 @@ typedef struct timelib_error_message {
} timelib_error_message;
typedef struct timelib_error_container {
- int warning_count;
+ struct timelib_error_message *error_messages;
struct timelib_error_message *warning_messages;
int error_count;
- struct timelib_error_message *error_messages;
+ int warning_count;
} timelib_error_container;
typedef struct _timelib_tz_lookup_table {
diff --git a/ext/date/lib/timezonedb.h b/ext/date/lib/timezonedb.h
index a23104f68c..98e7b2292c 100644
--- a/ext/date/lib/timezonedb.h
+++ b/ext/date/lib/timezonedb.h
@@ -12,578 +12,578 @@ const timelib_tzdb_index_entry timezonedb_idx_builtin[582] = {
{ "Africa/Blantyre" , 0x00052F },
{ "Africa/Brazzaville" , 0x000584 },
{ "Africa/Bujumbura" , 0x0005D9 },
- { "Africa/Cairo" , 0x00061D },
- { "Africa/Casablanca" , 0x000A04 },
- { "Africa/Ceuta" , 0x000C66 },
- { "Africa/Conakry" , 0x000F6D },
- { "Africa/Dakar" , 0x000FC2 },
- { "Africa/Dar_es_Salaam" , 0x001017 },
- { "Africa/Djibouti" , 0x001084 },
- { "Africa/Douala" , 0x0010D9 },
- { "Africa/El_Aaiun" , 0x00112E },
- { "Africa/Freetown" , 0x001359 },
- { "Africa/Gaborone" , 0x0013AE },
- { "Africa/Harare" , 0x00141B },
- { "Africa/Johannesburg" , 0x001470 },
- { "Africa/Juba" , 0x0014DE },
- { "Africa/Kampala" , 0x0015F1 },
- { "Africa/Khartoum" , 0x001670 },
- { "Africa/Kigali" , 0x001783 },
- { "Africa/Kinshasa" , 0x0017D8 },
- { "Africa/Lagos" , 0x001844 },
- { "Africa/Libreville" , 0x001899 },
- { "Africa/Lome" , 0x0018EE },
- { "Africa/Luanda" , 0x001943 },
- { "Africa/Lubumbashi" , 0x001998 },
- { "Africa/Lusaka" , 0x0019F3 },
- { "Africa/Malabo" , 0x001A48 },
- { "Africa/Maputo" , 0x001A9D },
- { "Africa/Maseru" , 0x001AF2 },
- { "Africa/Mbabane" , 0x001B5A },
- { "Africa/Mogadishu" , 0x001BB0 },
- { "Africa/Monrovia" , 0x001C0B },
- { "Africa/Nairobi" , 0x001C71 },
- { "Africa/Ndjamena" , 0x001CF0 },
- { "Africa/Niamey" , 0x001D5C },
- { "Africa/Nouakchott" , 0x001DB1 },
- { "Africa/Ouagadougou" , 0x001E06 },
- { "Africa/Porto-Novo" , 0x001E5B },
- { "Africa/Sao_Tome" , 0x001EB0 },
- { "Africa/Timbuktu" , 0x001F05 },
- { "Africa/Tripoli" , 0x001F5A },
- { "Africa/Tunis" , 0x002063 },
- { "Africa/Windhoek" , 0x002175 },
- { "America/Adak" , 0x0023BC },
- { "America/Anchorage" , 0x002732 },
- { "America/Anguilla" , 0x002AA6 },
- { "America/Antigua" , 0x002AFB },
- { "America/Araguaina" , 0x002B61 },
- { "America/Argentina/Buenos_Aires" , 0x002CC6 },
- { "America/Argentina/Catamarca" , 0x002E74 },
- { "America/Argentina/ComodRivadavia" , 0x003035 },
- { "America/Argentina/Cordoba" , 0x0031DB },
- { "America/Argentina/Jujuy" , 0x0033B0 },
- { "America/Argentina/La_Rioja" , 0x003564 },
- { "America/Argentina/Mendoza" , 0x00371C },
- { "America/Argentina/Rio_Gallegos" , 0x0038DC },
- { "America/Argentina/Salta" , 0x003A91 },
- { "America/Argentina/San_Juan" , 0x003C3D },
- { "America/Argentina/San_Luis" , 0x003DF5 },
- { "America/Argentina/Tucuman" , 0x003FBB },
- { "America/Argentina/Ushuaia" , 0x004177 },
- { "America/Aruba" , 0x004332 },
- { "America/Asuncion" , 0x004398 },
- { "America/Atikokan" , 0x00467D },
- { "America/Atka" , 0x004753 },
- { "America/Bahia" , 0x004AB9 },
- { "America/Bahia_Banderas" , 0x004C4C },
- { "America/Barbados" , 0x004EC5 },
- { "America/Belem" , 0x004F5F },
- { "America/Belize" , 0x00505A },
- { "America/Blanc-Sablon" , 0x0051D6 },
- { "America/Boa_Vista" , 0x00528A },
- { "America/Bogota" , 0x005393 },
- { "America/Boise" , 0x0053FF },
- { "America/Buenos_Aires" , 0x005796 },
- { "America/Cambridge_Bay" , 0x00592F },
- { "America/Campo_Grande" , 0x005C57 },
- { "America/Cancun" , 0x005F46 },
- { "America/Caracas" , 0x006188 },
- { "America/Catamarca" , 0x0061EF },
- { "America/Cayenne" , 0x006395 },
- { "America/Cayman" , 0x0063F7 },
- { "America/Chicago" , 0x00644C },
- { "America/Chihuahua" , 0x006963 },
- { "America/Coral_Harbour" , 0x006BCE },
- { "America/Cordoba" , 0x006C60 },
- { "America/Costa_Rica" , 0x006E06 },
- { "America/Creston" , 0x006E90 },
- { "America/Cuiaba" , 0x006F1C },
- { "America/Curacao" , 0x0071FA },
- { "America/Danmarkshavn" , 0x007260 },
- { "America/Dawson" , 0x0073A4 },
- { "America/Dawson_Creek" , 0x0076C1 },
- { "America/Denver" , 0x00789B },
- { "America/Detroit" , 0x007C21 },
- { "America/Dominica" , 0x007F80 },
- { "America/Edmonton" , 0x007FD5 },
- { "America/Eirunepe" , 0x00838D },
- { "America/El_Salvador" , 0x0084A5 },
- { "America/Ensenada" , 0x00851A },
- { "America/Fort_Wayne" , 0x0089C1 },
- { "America/Fortaleza" , 0x008883 },
- { "America/Glace_Bay" , 0x008C2B },
- { "America/Godthab" , 0x008FA2 },
- { "America/Goose_Bay" , 0x009266 },
- { "America/Grand_Turk" , 0x009723 },
- { "America/Grenada" , 0x0098F8 },
- { "America/Guadeloupe" , 0x00994D },
- { "America/Guatemala" , 0x0099A2 },
- { "America/Guayaquil" , 0x009A2B },
- { "America/Guyana" , 0x009A88 },
- { "America/Halifax" , 0x009B09 },
- { "America/Havana" , 0x00A01F },
- { "America/Hermosillo" , 0x00A392 },
- { "America/Indiana/Indianapolis" , 0x00A470 },
- { "America/Indiana/Knox" , 0x00A701 },
- { "America/Indiana/Marengo" , 0x00AA98 },
- { "America/Indiana/Petersburg" , 0x00AD3E },
- { "America/Indiana/Tell_City" , 0x00B28B },
- { "America/Indiana/Vevay" , 0x00B524 },
- { "America/Indiana/Vincennes" , 0x00B75F },
- { "America/Indiana/Winamac" , 0x00BA13 },
- { "America/Indianapolis" , 0x00B021 },
- { "America/Inuvik" , 0x00BCCC },
- { "America/Iqaluit" , 0x00BFC3 },
- { "America/Jamaica" , 0x00C2E5 },
- { "America/Jujuy" , 0x00C3AA },
- { "America/Juneau" , 0x00C554 },
- { "America/Kentucky/Louisville" , 0x00C8D2 },
- { "America/Kentucky/Monticello" , 0x00CCF0 },
- { "America/Knox_IN" , 0x00D075 },
- { "America/Kralendijk" , 0x00D3E6 },
- { "America/La_Paz" , 0x00D44C },
- { "America/Lima" , 0x00D4B3 },
- { "America/Los_Angeles" , 0x00D55B },
- { "America/Louisville" , 0x00D96C },
- { "America/Lower_Princes" , 0x00DD61 },
- { "America/Maceio" , 0x00DDC7 },
- { "America/Managua" , 0x00DF01 },
- { "America/Manaus" , 0x00DFB4 },
- { "America/Marigot" , 0x00E0B6 },
- { "America/Martinique" , 0x00E10B },
- { "America/Matamoros" , 0x00E177 },
- { "America/Mazatlan" , 0x00E3D0 },
- { "America/Mendoza" , 0x00E63D },
- { "America/Menominee" , 0x00E7F1 },
- { "America/Merida" , 0x00EB72 },
- { "America/Metlakatla" , 0x00EDAD },
- { "America/Mexico_City" , 0x00EEE8 },
- { "America/Miquelon" , 0x00F163 },
- { "America/Moncton" , 0x00F3D5 },
- { "America/Monterrey" , 0x00F86C },
- { "America/Montevideo" , 0x00FACF },
- { "America/Montreal" , 0x00FDE1 },
- { "America/Montserrat" , 0x0102D1 },
- { "America/Nassau" , 0x010326 },
- { "America/New_York" , 0x01066B },
- { "America/Nipigon" , 0x010B76 },
- { "America/Nome" , 0x010EC7 },
- { "America/Noronha" , 0x011245 },
- { "America/North_Dakota/Beulah" , 0x011375 },
- { "America/North_Dakota/Center" , 0x011709 },
- { "America/North_Dakota/New_Salem" , 0x011A9D },
- { "America/Ojinaga" , 0x011E46 },
- { "America/Panama" , 0x0120A7 },
- { "America/Pangnirtung" , 0x0120FC },
- { "America/Paramaribo" , 0x012432 },
- { "America/Phoenix" , 0x0124C4 },
- { "America/Port-au-Prince" , 0x012582 },
- { "America/Port_of_Spain" , 0x0128A6 },
- { "America/Porto_Acre" , 0x0127A2 },
- { "America/Porto_Velho" , 0x0128FB },
- { "America/Puerto_Rico" , 0x0129F1 },
- { "America/Rainy_River" , 0x012A5C },
- { "America/Rankin_Inlet" , 0x012D94 },
- { "America/Recife" , 0x01307A },
- { "America/Regina" , 0x0131A4 },
- { "America/Resolute" , 0x013362 },
- { "America/Rio_Branco" , 0x01364A },
- { "America/Rosario" , 0x013752 },
- { "America/Santa_Isabel" , 0x0138F8 },
- { "America/Santarem" , 0x013C9B },
- { "America/Santiago" , 0x013DA0 },
- { "America/Santo_Domingo" , 0x014149 },
- { "America/Sao_Paulo" , 0x01420F },
- { "America/Scoresbysund" , 0x01451E },
- { "America/Shiprock" , 0x01480C },
- { "America/Sitka" , 0x014B85 },
- { "America/St_Barthelemy" , 0x014F0D },
- { "America/St_Johns" , 0x014F62 },
- { "America/St_Kitts" , 0x0154B5 },
- { "America/St_Lucia" , 0x01550A },
- { "America/St_Thomas" , 0x01555F },
- { "America/St_Vincent" , 0x0155B4 },
- { "America/Swift_Current" , 0x015609 },
- { "America/Tegucigalpa" , 0x01572A },
- { "America/Thule" , 0x0157A9 },
- { "America/Thunder_Bay" , 0x0159F0 },
- { "America/Tijuana" , 0x015D39 },
- { "America/Toronto" , 0x0160D2 },
- { "America/Tortola" , 0x0165F2 },
- { "America/Vancouver" , 0x016647 },
- { "America/Virgin" , 0x016A84 },
- { "America/Whitehorse" , 0x016AD9 },
- { "America/Winnipeg" , 0x016DF6 },
- { "America/Yakutat" , 0x017236 },
- { "America/Yellowknife" , 0x0175A1 },
- { "Antarctica/Casey" , 0x0178B1 },
- { "Antarctica/Davis" , 0x01794F },
- { "Antarctica/DumontDUrville" , 0x0179F0 },
- { "Antarctica/Macquarie" , 0x017A81 },
- { "Antarctica/Mawson" , 0x017CCE },
- { "Antarctica/McMurdo" , 0x017D4A },
- { "Antarctica/Palmer" , 0x0180F5 },
- { "Antarctica/Rothera" , 0x018411 },
- { "Antarctica/South_Pole" , 0x018487 },
- { "Antarctica/Syowa" , 0x018805 },
- { "Antarctica/Troll" , 0x018873 },
- { "Antarctica/Vostok" , 0x018A45 },
- { "Arctic/Longyearbyen" , 0x018AB6 },
- { "Asia/Aden" , 0x018DE8 },
- { "Asia/Almaty" , 0x018E3D },
- { "Asia/Amman" , 0x018FBC },
- { "Asia/Anadyr" , 0x019272 },
- { "Asia/Aqtau" , 0x019474 },
- { "Asia/Aqtobe" , 0x019673 },
- { "Asia/Ashgabat" , 0x01982B },
- { "Asia/Ashkhabad" , 0x019948 },
- { "Asia/Baghdad" , 0x019A65 },
- { "Asia/Bahrain" , 0x019BDA },
- { "Asia/Baku" , 0x019C40 },
- { "Asia/Bangkok" , 0x019F28 },
- { "Asia/Beirut" , 0x019F7D },
- { "Asia/Bishkek" , 0x01A28A },
- { "Asia/Brunei" , 0x01A436 },
- { "Asia/Calcutta" , 0x01A498 },
- { "Asia/Chita" , 0x01A511 },
- { "Asia/Choibalsan" , 0x01A726 },
- { "Asia/Chongqing" , 0x01A89F },
- { "Asia/Chungking" , 0x01A93F },
- { "Asia/Colombo" , 0x01A9DF },
- { "Asia/Dacca" , 0x01AA7B },
- { "Asia/Damascus" , 0x01AB21 },
- { "Asia/Dhaka" , 0x01AE71 },
- { "Asia/Dili" , 0x01AF17 },
- { "Asia/Dubai" , 0x01AFA1 },
- { "Asia/Dushanbe" , 0x01AFF6 },
- { "Asia/Gaza" , 0x01B0F9 },
- { "Asia/Harbin" , 0x01B44C },
- { "Asia/Hebron" , 0x01B4EC },
- { "Asia/Ho_Chi_Minh" , 0x01B848 },
- { "Asia/Hong_Kong" , 0x01B8C0 },
- { "Asia/Hovd" , 0x01BA82 },
- { "Asia/Irkutsk" , 0x01BBFA },
- { "Asia/Istanbul" , 0x01BDE5 },
- { "Asia/Jakarta" , 0x01C1D2 },
- { "Asia/Jayapura" , 0x01C27C },
- { "Asia/Jerusalem" , 0x01C319 },
- { "Asia/Kabul" , 0x01C648 },
- { "Asia/Kamchatka" , 0x01C699 },
- { "Asia/Karachi" , 0x01C892 },
- { "Asia/Kashgar" , 0x01C947 },
- { "Asia/Kathmandu" , 0x01C99C },
- { "Asia/Katmandu" , 0x01CA02 },
- { "Asia/Khandyga" , 0x01CA68 },
- { "Asia/Kolkata" , 0x01CC92 },
- { "Asia/Krasnoyarsk" , 0x01CD0B },
- { "Asia/Kuala_Lumpur" , 0x01CEF8 },
- { "Asia/Kuching" , 0x01CFB5 },
- { "Asia/Kuwait" , 0x01D0A3 },
- { "Asia/Macao" , 0x01D0F8 },
- { "Asia/Macau" , 0x01D233 },
- { "Asia/Magadan" , 0x01D36E },
- { "Asia/Makassar" , 0x01D572 },
- { "Asia/Manila" , 0x01D637 },
- { "Asia/Muscat" , 0x01D6BC },
- { "Asia/Nicosia" , 0x01D711 },
- { "Asia/Novokuznetsk" , 0x01D9F9 },
- { "Asia/Novosibirsk" , 0x01DC19 },
- { "Asia/Omsk" , 0x01DE09 },
- { "Asia/Oral" , 0x01DFF5 },
- { "Asia/Phnom_Penh" , 0x01E1C5 },
- { "Asia/Pontianak" , 0x01E23D },
- { "Asia/Pyongyang" , 0x01E2FF },
- { "Asia/Qatar" , 0x01E38F },
- { "Asia/Qyzylorda" , 0x01E3F5 },
- { "Asia/Rangoon" , 0x01E5CB },
- { "Asia/Riyadh" , 0x01E643 },
- { "Asia/Saigon" , 0x01E698 },
- { "Asia/Sakhalin" , 0x01E710 },
- { "Asia/Samarkand" , 0x01E90D },
- { "Asia/Seoul" , 0x01EA43 },
- { "Asia/Shanghai" , 0x01EB0A },
- { "Asia/Singapore" , 0x01EBB6 },
- { "Asia/Srednekolymsk" , 0x01EC6D },
- { "Asia/Taipei" , 0x01EE6D },
- { "Asia/Tashkent" , 0x01EF9E },
- { "Asia/Tbilisi" , 0x01F0CF },
- { "Asia/Tehran" , 0x01F289 },
- { "Asia/Tel_Aviv" , 0x01F4F7 },
- { "Asia/Thimbu" , 0x01F826 },
- { "Asia/Thimphu" , 0x01F88C },
- { "Asia/Tokyo" , 0x01F8F2 },
- { "Asia/Ujung_Pandang" , 0x01F97C },
- { "Asia/Ulaanbaatar" , 0x01F9F9 },
- { "Asia/Ulan_Bator" , 0x01FB54 },
- { "Asia/Urumqi" , 0x01FCA1 },
- { "Asia/Ust-Nera" , 0x01FD03 },
- { "Asia/Vientiane" , 0x01FF15 },
- { "Asia/Vladivostok" , 0x01FF8D },
- { "Asia/Yakutsk" , 0x020177 },
- { "Asia/Yekaterinburg" , 0x020361 },
- { "Asia/Yerevan" , 0x020582 },
- { "Atlantic/Azores" , 0x020782 },
- { "Atlantic/Bermuda" , 0x020C85 },
- { "Atlantic/Canary" , 0x020F66 },
- { "Atlantic/Cape_Verde" , 0x02123C },
- { "Atlantic/Faeroe" , 0x0212B5 },
- { "Atlantic/Faroe" , 0x021559 },
- { "Atlantic/Jan_Mayen" , 0x0217FD },
- { "Atlantic/Madeira" , 0x021B2F },
- { "Atlantic/Reykjavik" , 0x022038 },
- { "Atlantic/South_Georgia" , 0x0221F1 },
- { "Atlantic/St_Helena" , 0x022403 },
- { "Atlantic/Stanley" , 0x022235 },
- { "Australia/ACT" , 0x022458 },
- { "Australia/Adelaide" , 0x02277B },
- { "Australia/Brisbane" , 0x022AAD },
- { "Australia/Broken_Hill" , 0x022B7A },
- { "Australia/Canberra" , 0x022EBE },
- { "Australia/Currie" , 0x0231E1 },
- { "Australia/Darwin" , 0x02351A },
- { "Australia/Eucla" , 0x0235A6 },
- { "Australia/Hobart" , 0x023682 },
- { "Australia/LHI" , 0x0239E6 },
- { "Australia/Lindeman" , 0x023C87 },
- { "Australia/Lord_Howe" , 0x023D6E },
- { "Australia/Melbourne" , 0x02401F },
- { "Australia/North" , 0x02434A },
- { "Australia/NSW" , 0x0243C4 },
- { "Australia/Perth" , 0x0246E7 },
- { "Australia/Queensland" , 0x0247C5 },
- { "Australia/South" , 0x024877 },
- { "Australia/Sydney" , 0x024B9A },
- { "Australia/Tasmania" , 0x024EDD },
- { "Australia/Victoria" , 0x025228 },
- { "Australia/West" , 0x02554B },
- { "Australia/Yancowinna" , 0x025607 },
- { "Brazil/Acre" , 0x02592F },
- { "Brazil/DeNoronha" , 0x025A33 },
- { "Brazil/East" , 0x025B53 },
- { "Brazil/West" , 0x025E30 },
- { "Canada/Atlantic" , 0x025F28 },
- { "Canada/Central" , 0x026410 },
- { "Canada/East-Saskatchewan" , 0x026D1A },
- { "Canada/Eastern" , 0x02682A },
- { "Canada/Mountain" , 0x026EA3 },
- { "Canada/Newfoundland" , 0x027219 },
- { "Canada/Pacific" , 0x027744 },
- { "Canada/Saskatchewan" , 0x027B5D },
- { "Canada/Yukon" , 0x027CE6 },
- { "CET" , 0x027FE9 },
- { "Chile/Continental" , 0x0282F2 },
- { "Chile/EasterIsland" , 0x02868D },
- { "CST6CDT" , 0x0289CF },
- { "Cuba" , 0x028D20 },
- { "EET" , 0x029093 },
- { "Egypt" , 0x029346 },
- { "Eire" , 0x02972D },
- { "EST" , 0x029C3E },
- { "EST5EDT" , 0x029C82 },
- { "Etc/GMT" , 0x029FD3 },
- { "Etc/GMT+0" , 0x02A09F },
- { "Etc/GMT+1" , 0x02A129 },
- { "Etc/GMT+10" , 0x02A1B6 },
- { "Etc/GMT+11" , 0x02A244 },
- { "Etc/GMT+12" , 0x02A2D2 },
- { "Etc/GMT+2" , 0x02A3ED },
- { "Etc/GMT+3" , 0x02A479 },
- { "Etc/GMT+4" , 0x02A505 },
- { "Etc/GMT+5" , 0x02A591 },
- { "Etc/GMT+6" , 0x02A61D },
- { "Etc/GMT+7" , 0x02A6A9 },
- { "Etc/GMT+8" , 0x02A735 },
- { "Etc/GMT+9" , 0x02A7C1 },
- { "Etc/GMT-0" , 0x02A05B },
- { "Etc/GMT-1" , 0x02A0E3 },
- { "Etc/GMT-10" , 0x02A16F },
- { "Etc/GMT-11" , 0x02A1FD },
- { "Etc/GMT-12" , 0x02A28B },
- { "Etc/GMT-13" , 0x02A319 },
- { "Etc/GMT-14" , 0x02A360 },
- { "Etc/GMT-2" , 0x02A3A7 },
- { "Etc/GMT-3" , 0x02A433 },
- { "Etc/GMT-4" , 0x02A4BF },
- { "Etc/GMT-5" , 0x02A54B },
- { "Etc/GMT-6" , 0x02A5D7 },
- { "Etc/GMT-7" , 0x02A663 },
- { "Etc/GMT-8" , 0x02A6EF },
- { "Etc/GMT-9" , 0x02A77B },
- { "Etc/GMT0" , 0x02A017 },
- { "Etc/Greenwich" , 0x02A807 },
- { "Etc/UCT" , 0x02A84B },
- { "Etc/Universal" , 0x02A88F },
- { "Etc/UTC" , 0x02A8D3 },
- { "Etc/Zulu" , 0x02A917 },
- { "Europe/Amsterdam" , 0x02A95B },
- { "Europe/Andorra" , 0x02AD99 },
- { "Europe/Athens" , 0x02B015 },
- { "Europe/Belfast" , 0x02B358 },
- { "Europe/Belgrade" , 0x02B88F },
- { "Europe/Berlin" , 0x02BB58 },
- { "Europe/Bratislava" , 0x02BEBC },
- { "Europe/Brussels" , 0x02C1EE },
- { "Europe/Bucharest" , 0x02C625 },
- { "Europe/Budapest" , 0x02C94F },
- { "Europe/Busingen" , 0x02CCB8 },
- { "Europe/Chisinau" , 0x02CF6F },
- { "Europe/Copenhagen" , 0x02D2FD },
- { "Europe/Dublin" , 0x02D607 },
- { "Europe/Gibraltar" , 0x02DB18 },
- { "Europe/Guernsey" , 0x02DF6F },
- { "Europe/Helsinki" , 0x02E4A6 },
- { "Europe/Isle_of_Man" , 0x02E75C },
- { "Europe/Istanbul" , 0x02EC93 },
- { "Europe/Jersey" , 0x02F080 },
- { "Europe/Kaliningrad" , 0x02F5B7 },
- { "Europe/Kiev" , 0x02F822 },
- { "Europe/Lisbon" , 0x02FB3E },
- { "Europe/Ljubljana" , 0x030042 },
- { "Europe/London" , 0x03030B },
- { "Europe/Luxembourg" , 0x030842 },
- { "Europe/Madrid" , 0x030C98 },
- { "Europe/Malta" , 0x03105E },
- { "Europe/Mariehamn" , 0x031417 },
- { "Europe/Minsk" , 0x0316CD },
- { "Europe/Monaco" , 0x0318DB },
- { "Europe/Moscow" , 0x031D16 },
- { "Europe/Nicosia" , 0x031F70 },
- { "Europe/Oslo" , 0x032258 },
- { "Europe/Paris" , 0x03258A },
- { "Europe/Podgorica" , 0x0329D0 },
- { "Europe/Prague" , 0x032C99 },
- { "Europe/Riga" , 0x032FCB },
- { "Europe/Rome" , 0x033310 },
- { "Europe/Samara" , 0x0336D3 },
- { "Europe/San_Marino" , 0x03393C },
- { "Europe/Sarajevo" , 0x033CFF },
- { "Europe/Simferopol" , 0x033FC8 },
- { "Europe/Skopje" , 0x034219 },
- { "Europe/Sofia" , 0x0344E2 },
- { "Europe/Stockholm" , 0x0347EA },
- { "Europe/Tallinn" , 0x034A99 },
- { "Europe/Tirane" , 0x034DD3 },
- { "Europe/Tiraspol" , 0x0350D9 },
- { "Europe/Uzhgorod" , 0x035467 },
- { "Europe/Vaduz" , 0x03577E },
- { "Europe/Vatican" , 0x035A2D },
- { "Europe/Vienna" , 0x035DF0 },
- { "Europe/Vilnius" , 0x03611D },
- { "Europe/Volgograd" , 0x03645C },
- { "Europe/Warsaw" , 0x03667D },
- { "Europe/Zagreb" , 0x036A5E },
- { "Europe/Zaporozhye" , 0x036D27 },
- { "Europe/Zurich" , 0x037068 },
- { "Factory" , 0x037317 },
- { "GB" , 0x037388 },
- { "GB-Eire" , 0x0378BF },
- { "GMT" , 0x037DF6 },
- { "GMT+0" , 0x037EC2 },
- { "GMT-0" , 0x037E7E },
- { "GMT0" , 0x037E3A },
- { "Greenwich" , 0x037F06 },
- { "Hongkong" , 0x037F4A },
- { "HST" , 0x03810C },
- { "Iceland" , 0x038150 },
- { "Indian/Antananarivo" , 0x038309 },
- { "Indian/Chagos" , 0x03837D },
- { "Indian/Christmas" , 0x0383DF },
- { "Indian/Cocos" , 0x038423 },
- { "Indian/Comoro" , 0x038467 },
- { "Indian/Kerguelen" , 0x0384BC },
- { "Indian/Mahe" , 0x038511 },
- { "Indian/Maldives" , 0x038566 },
- { "Indian/Mauritius" , 0x0385BB },
- { "Indian/Mayotte" , 0x038631 },
- { "Indian/Reunion" , 0x038686 },
- { "Iran" , 0x0386DB },
- { "Israel" , 0x038949 },
- { "Jamaica" , 0x038C78 },
- { "Japan" , 0x038D3D },
- { "Kwajalein" , 0x038DC7 },
- { "Libya" , 0x038E2A },
- { "MET" , 0x038F33 },
- { "Mexico/BajaNorte" , 0x03923C },
- { "Mexico/BajaSur" , 0x0395A5 },
- { "Mexico/General" , 0x0397EA },
- { "MST" , 0x039A48 },
- { "MST7MDT" , 0x039A8C },
- { "Navajo" , 0x039DDD },
- { "NZ" , 0x03A156 },
- { "NZ-CHAT" , 0x03A4D4 },
- { "Pacific/Apia" , 0x03A7B8 },
- { "Pacific/Auckland" , 0x03A954 },
- { "Pacific/Chatham" , 0x03ACE0 },
- { "Pacific/Chuuk" , 0x03AFD3 },
- { "Pacific/Easter" , 0x03B02C },
- { "Pacific/Efate" , 0x03B37B },
- { "Pacific/Enderbury" , 0x03B441 },
- { "Pacific/Fakaofo" , 0x03B4AF },
- { "Pacific/Fiji" , 0x03B500 },
- { "Pacific/Funafuti" , 0x03B693 },
- { "Pacific/Galapagos" , 0x03B6D7 },
- { "Pacific/Gambier" , 0x03B74F },
- { "Pacific/Guadalcanal" , 0x03B7B4 },
- { "Pacific/Guam" , 0x03B809 },
- { "Pacific/Honolulu" , 0x03B85F },
- { "Pacific/Johnston" , 0x03B8D6 },
- { "Pacific/Kiritimati" , 0x03B955 },
- { "Pacific/Kosrae" , 0x03B9C0 },
- { "Pacific/Kwajalein" , 0x03BA1D },
- { "Pacific/Majuro" , 0x03BA89 },
- { "Pacific/Marquesas" , 0x03BAE8 },
- { "Pacific/Midway" , 0x03BB4F },
- { "Pacific/Nauru" , 0x03BBD9 },
- { "Pacific/Niue" , 0x03BC51 },
- { "Pacific/Norfolk" , 0x03BCAF },
- { "Pacific/Noumea" , 0x03BD04 },
- { "Pacific/Pago_Pago" , 0x03BD94 },
- { "Pacific/Palau" , 0x03BE0B },
- { "Pacific/Pitcairn" , 0x03BE4F },
- { "Pacific/Pohnpei" , 0x03BEA4 },
- { "Pacific/Ponape" , 0x03BEF9 },
- { "Pacific/Port_Moresby" , 0x03BF3E },
- { "Pacific/Rarotonga" , 0x03BF82 },
- { "Pacific/Saipan" , 0x03C05E },
- { "Pacific/Samoa" , 0x03C0C1 },
- { "Pacific/Tahiti" , 0x03C138 },
- { "Pacific/Tarawa" , 0x03C19D },
- { "Pacific/Tongatapu" , 0x03C1F1 },
- { "Pacific/Truk" , 0x03C27D },
- { "Pacific/Wake" , 0x03C2C2 },
- { "Pacific/Wallis" , 0x03C312 },
- { "Pacific/Yap" , 0x03C356 },
- { "Poland" , 0x03C39B },
- { "Portugal" , 0x03C77C },
- { "PRC" , 0x03CC78 },
- { "PST8PDT" , 0x03CD18 },
- { "ROC" , 0x03D069 },
- { "ROK" , 0x03D19A },
- { "Singapore" , 0x03D261 },
- { "Turkey" , 0x03D318 },
- { "UCT" , 0x03D705 },
- { "Universal" , 0x03D749 },
- { "US/Alaska" , 0x03D78D },
- { "US/Aleutian" , 0x03DAF6 },
- { "US/Arizona" , 0x03DE5C },
- { "US/Central" , 0x03DEEA },
- { "US/East-Indiana" , 0x03E8F4 },
- { "US/Eastern" , 0x03E3F5 },
- { "US/Hawaii" , 0x03EB5E },
- { "US/Indiana-Starke" , 0x03EBCF },
- { "US/Michigan" , 0x03EF40 },
- { "US/Mountain" , 0x03F277 },
- { "US/Pacific" , 0x03F5F0 },
- { "US/Pacific-New" , 0x03F9F5 },
- { "US/Samoa" , 0x03FDFA },
- { "UTC" , 0x03FE71 },
- { "W-SU" , 0x040168 },
- { "WET" , 0x03FEB5 },
- { "Zulu" , 0x0403AB },
+ { "Africa/Cairo" , 0x00062E },
+ { "Africa/Casablanca" , 0x000A15 },
+ { "Africa/Ceuta" , 0x000C77 },
+ { "Africa/Conakry" , 0x000F7E },
+ { "Africa/Dakar" , 0x000FD3 },
+ { "Africa/Dar_es_Salaam" , 0x001028 },
+ { "Africa/Djibouti" , 0x001095 },
+ { "Africa/Douala" , 0x0010EA },
+ { "Africa/El_Aaiun" , 0x00113F },
+ { "Africa/Freetown" , 0x00136A },
+ { "Africa/Gaborone" , 0x0013BF },
+ { "Africa/Harare" , 0x001414 },
+ { "Africa/Johannesburg" , 0x001469 },
+ { "Africa/Juba" , 0x0014D7 },
+ { "Africa/Kampala" , 0x0015EA },
+ { "Africa/Khartoum" , 0x001669 },
+ { "Africa/Kigali" , 0x00177C },
+ { "Africa/Kinshasa" , 0x0017D1 },
+ { "Africa/Lagos" , 0x00183D },
+ { "Africa/Libreville" , 0x001892 },
+ { "Africa/Lome" , 0x0018E7 },
+ { "Africa/Luanda" , 0x00193C },
+ { "Africa/Lubumbashi" , 0x001991 },
+ { "Africa/Lusaka" , 0x0019FD },
+ { "Africa/Malabo" , 0x001A52 },
+ { "Africa/Maputo" , 0x001AA7 },
+ { "Africa/Maseru" , 0x001AFC },
+ { "Africa/Mbabane" , 0x001B6A },
+ { "Africa/Mogadishu" , 0x001BD8 },
+ { "Africa/Monrovia" , 0x001C33 },
+ { "Africa/Nairobi" , 0x001C99 },
+ { "Africa/Ndjamena" , 0x001D18 },
+ { "Africa/Niamey" , 0x001D84 },
+ { "Africa/Nouakchott" , 0x001DD9 },
+ { "Africa/Ouagadougou" , 0x001E2E },
+ { "Africa/Porto-Novo" , 0x001E83 },
+ { "Africa/Sao_Tome" , 0x001ED8 },
+ { "Africa/Timbuktu" , 0x001F2D },
+ { "Africa/Tripoli" , 0x001F82 },
+ { "Africa/Tunis" , 0x00208B },
+ { "Africa/Windhoek" , 0x00219D },
+ { "America/Adak" , 0x0023E4 },
+ { "America/Anchorage" , 0x00275A },
+ { "America/Anguilla" , 0x002ACE },
+ { "America/Antigua" , 0x002B23 },
+ { "America/Araguaina" , 0x002B89 },
+ { "America/Argentina/Buenos_Aires" , 0x002CEE },
+ { "America/Argentina/Catamarca" , 0x002E9C },
+ { "America/Argentina/ComodRivadavia" , 0x00305D },
+ { "America/Argentina/Cordoba" , 0x003203 },
+ { "America/Argentina/Jujuy" , 0x0033D8 },
+ { "America/Argentina/La_Rioja" , 0x00358C },
+ { "America/Argentina/Mendoza" , 0x003744 },
+ { "America/Argentina/Rio_Gallegos" , 0x003904 },
+ { "America/Argentina/Salta" , 0x003AB9 },
+ { "America/Argentina/San_Juan" , 0x003C65 },
+ { "America/Argentina/San_Luis" , 0x003E1D },
+ { "America/Argentina/Tucuman" , 0x003FE3 },
+ { "America/Argentina/Ushuaia" , 0x00419F },
+ { "America/Aruba" , 0x00435A },
+ { "America/Asuncion" , 0x0043C0 },
+ { "America/Atikokan" , 0x0046A5 },
+ { "America/Atka" , 0x00477B },
+ { "America/Bahia" , 0x004AE1 },
+ { "America/Bahia_Banderas" , 0x004C74 },
+ { "America/Barbados" , 0x004EED },
+ { "America/Belem" , 0x004F87 },
+ { "America/Belize" , 0x005082 },
+ { "America/Blanc-Sablon" , 0x0051FE },
+ { "America/Boa_Vista" , 0x0052B2 },
+ { "America/Bogota" , 0x0053BB },
+ { "America/Boise" , 0x005427 },
+ { "America/Buenos_Aires" , 0x0057BE },
+ { "America/Cambridge_Bay" , 0x005957 },
+ { "America/Campo_Grande" , 0x005C7F },
+ { "America/Cancun" , 0x005F6E },
+ { "America/Caracas" , 0x0061B0 },
+ { "America/Catamarca" , 0x006217 },
+ { "America/Cayenne" , 0x0063BD },
+ { "America/Cayman" , 0x00641F },
+ { "America/Chicago" , 0x006474 },
+ { "America/Chihuahua" , 0x00698B },
+ { "America/Coral_Harbour" , 0x006BF6 },
+ { "America/Cordoba" , 0x006C88 },
+ { "America/Costa_Rica" , 0x006E2E },
+ { "America/Creston" , 0x006EB8 },
+ { "America/Cuiaba" , 0x006F44 },
+ { "America/Curacao" , 0x007222 },
+ { "America/Danmarkshavn" , 0x007288 },
+ { "America/Dawson" , 0x0073CC },
+ { "America/Dawson_Creek" , 0x0076E9 },
+ { "America/Denver" , 0x0078C3 },
+ { "America/Detroit" , 0x007C49 },
+ { "America/Dominica" , 0x007FA8 },
+ { "America/Edmonton" , 0x007FFD },
+ { "America/Eirunepe" , 0x0083B5 },
+ { "America/El_Salvador" , 0x0084CD },
+ { "America/Ensenada" , 0x008542 },
+ { "America/Fort_Wayne" , 0x0089E9 },
+ { "America/Fortaleza" , 0x0088AB },
+ { "America/Glace_Bay" , 0x008C53 },
+ { "America/Godthab" , 0x008FCA },
+ { "America/Goose_Bay" , 0x00928E },
+ { "America/Grand_Turk" , 0x00974B },
+ { "America/Grenada" , 0x009920 },
+ { "America/Guadeloupe" , 0x009975 },
+ { "America/Guatemala" , 0x0099CA },
+ { "America/Guayaquil" , 0x009A53 },
+ { "America/Guyana" , 0x009AB0 },
+ { "America/Halifax" , 0x009B31 },
+ { "America/Havana" , 0x00A047 },
+ { "America/Hermosillo" , 0x00A3BA },
+ { "America/Indiana/Indianapolis" , 0x00A498 },
+ { "America/Indiana/Knox" , 0x00A729 },
+ { "America/Indiana/Marengo" , 0x00AAC0 },
+ { "America/Indiana/Petersburg" , 0x00AD66 },
+ { "America/Indiana/Tell_City" , 0x00B2B3 },
+ { "America/Indiana/Vevay" , 0x00B54C },
+ { "America/Indiana/Vincennes" , 0x00B787 },
+ { "America/Indiana/Winamac" , 0x00BA3B },
+ { "America/Indianapolis" , 0x00B049 },
+ { "America/Inuvik" , 0x00BCF4 },
+ { "America/Iqaluit" , 0x00BFEB },
+ { "America/Jamaica" , 0x00C30D },
+ { "America/Jujuy" , 0x00C3D2 },
+ { "America/Juneau" , 0x00C57C },
+ { "America/Kentucky/Louisville" , 0x00C8FA },
+ { "America/Kentucky/Monticello" , 0x00CD18 },
+ { "America/Knox_IN" , 0x00D09D },
+ { "America/Kralendijk" , 0x00D40E },
+ { "America/La_Paz" , 0x00D474 },
+ { "America/Lima" , 0x00D4DB },
+ { "America/Los_Angeles" , 0x00D583 },
+ { "America/Louisville" , 0x00D994 },
+ { "America/Lower_Princes" , 0x00DD89 },
+ { "America/Maceio" , 0x00DDEF },
+ { "America/Managua" , 0x00DF29 },
+ { "America/Manaus" , 0x00DFDC },
+ { "America/Marigot" , 0x00E0DE },
+ { "America/Martinique" , 0x00E133 },
+ { "America/Matamoros" , 0x00E19F },
+ { "America/Mazatlan" , 0x00E3F8 },
+ { "America/Mendoza" , 0x00E665 },
+ { "America/Menominee" , 0x00E819 },
+ { "America/Merida" , 0x00EB9A },
+ { "America/Metlakatla" , 0x00EDD5 },
+ { "America/Mexico_City" , 0x00EF10 },
+ { "America/Miquelon" , 0x00F18B },
+ { "America/Moncton" , 0x00F3FD },
+ { "America/Monterrey" , 0x00F894 },
+ { "America/Montevideo" , 0x00FAF7 },
+ { "America/Montreal" , 0x00FE09 },
+ { "America/Montserrat" , 0x0102F9 },
+ { "America/Nassau" , 0x01034E },
+ { "America/New_York" , 0x010693 },
+ { "America/Nipigon" , 0x010B9E },
+ { "America/Nome" , 0x010EEF },
+ { "America/Noronha" , 0x01126D },
+ { "America/North_Dakota/Beulah" , 0x01139D },
+ { "America/North_Dakota/Center" , 0x011731 },
+ { "America/North_Dakota/New_Salem" , 0x011AC5 },
+ { "America/Ojinaga" , 0x011E6E },
+ { "America/Panama" , 0x0120CF },
+ { "America/Pangnirtung" , 0x012124 },
+ { "America/Paramaribo" , 0x01245A },
+ { "America/Phoenix" , 0x0124EC },
+ { "America/Port-au-Prince" , 0x0125AA },
+ { "America/Port_of_Spain" , 0x0128CE },
+ { "America/Porto_Acre" , 0x0127CA },
+ { "America/Porto_Velho" , 0x012923 },
+ { "America/Puerto_Rico" , 0x012A19 },
+ { "America/Rainy_River" , 0x012A84 },
+ { "America/Rankin_Inlet" , 0x012DBC },
+ { "America/Recife" , 0x0130A2 },
+ { "America/Regina" , 0x0131CC },
+ { "America/Resolute" , 0x01338A },
+ { "America/Rio_Branco" , 0x013672 },
+ { "America/Rosario" , 0x01377A },
+ { "America/Santa_Isabel" , 0x013920 },
+ { "America/Santarem" , 0x013CC3 },
+ { "America/Santiago" , 0x013DC8 },
+ { "America/Santo_Domingo" , 0x014171 },
+ { "America/Sao_Paulo" , 0x014237 },
+ { "America/Scoresbysund" , 0x014546 },
+ { "America/Shiprock" , 0x014834 },
+ { "America/Sitka" , 0x014BAD },
+ { "America/St_Barthelemy" , 0x014F35 },
+ { "America/St_Johns" , 0x014F8A },
+ { "America/St_Kitts" , 0x0154DD },
+ { "America/St_Lucia" , 0x015532 },
+ { "America/St_Thomas" , 0x015587 },
+ { "America/St_Vincent" , 0x0155DC },
+ { "America/Swift_Current" , 0x015631 },
+ { "America/Tegucigalpa" , 0x015752 },
+ { "America/Thule" , 0x0157D1 },
+ { "America/Thunder_Bay" , 0x015A18 },
+ { "America/Tijuana" , 0x015D61 },
+ { "America/Toronto" , 0x0160FA },
+ { "America/Tortola" , 0x01661A },
+ { "America/Vancouver" , 0x01666F },
+ { "America/Virgin" , 0x016AAC },
+ { "America/Whitehorse" , 0x016B01 },
+ { "America/Winnipeg" , 0x016E1E },
+ { "America/Yakutat" , 0x01725E },
+ { "America/Yellowknife" , 0x0175C9 },
+ { "Antarctica/Casey" , 0x0178D9 },
+ { "Antarctica/Davis" , 0x017977 },
+ { "Antarctica/DumontDUrville" , 0x017A18 },
+ { "Antarctica/Macquarie" , 0x017AA9 },
+ { "Antarctica/Mawson" , 0x017CF6 },
+ { "Antarctica/McMurdo" , 0x017D72 },
+ { "Antarctica/Palmer" , 0x01811D },
+ { "Antarctica/Rothera" , 0x018439 },
+ { "Antarctica/South_Pole" , 0x0184AF },
+ { "Antarctica/Syowa" , 0x01882D },
+ { "Antarctica/Troll" , 0x01889B },
+ { "Antarctica/Vostok" , 0x018A6D },
+ { "Arctic/Longyearbyen" , 0x018ADE },
+ { "Asia/Aden" , 0x018E10 },
+ { "Asia/Almaty" , 0x018E65 },
+ { "Asia/Amman" , 0x018FE4 },
+ { "Asia/Anadyr" , 0x01929A },
+ { "Asia/Aqtau" , 0x01949C },
+ { "Asia/Aqtobe" , 0x01969B },
+ { "Asia/Ashgabat" , 0x019853 },
+ { "Asia/Ashkhabad" , 0x019970 },
+ { "Asia/Baghdad" , 0x019A8D },
+ { "Asia/Bahrain" , 0x019C02 },
+ { "Asia/Baku" , 0x019C68 },
+ { "Asia/Bangkok" , 0x019F50 },
+ { "Asia/Beirut" , 0x019FA5 },
+ { "Asia/Bishkek" , 0x01A2B2 },
+ { "Asia/Brunei" , 0x01A45E },
+ { "Asia/Calcutta" , 0x01A4C0 },
+ { "Asia/Chita" , 0x01A539 },
+ { "Asia/Choibalsan" , 0x01A74E },
+ { "Asia/Chongqing" , 0x01A8C7 },
+ { "Asia/Chungking" , 0x01A967 },
+ { "Asia/Colombo" , 0x01AA07 },
+ { "Asia/Dacca" , 0x01AAA3 },
+ { "Asia/Damascus" , 0x01AB49 },
+ { "Asia/Dhaka" , 0x01AE99 },
+ { "Asia/Dili" , 0x01AF3F },
+ { "Asia/Dubai" , 0x01AFC9 },
+ { "Asia/Dushanbe" , 0x01B01E },
+ { "Asia/Gaza" , 0x01B121 },
+ { "Asia/Harbin" , 0x01B474 },
+ { "Asia/Hebron" , 0x01B514 },
+ { "Asia/Ho_Chi_Minh" , 0x01B870 },
+ { "Asia/Hong_Kong" , 0x01B8E8 },
+ { "Asia/Hovd" , 0x01BAAA },
+ { "Asia/Irkutsk" , 0x01BC22 },
+ { "Asia/Istanbul" , 0x01BE0D },
+ { "Asia/Jakarta" , 0x01C1FA },
+ { "Asia/Jayapura" , 0x01C2A4 },
+ { "Asia/Jerusalem" , 0x01C341 },
+ { "Asia/Kabul" , 0x01C670 },
+ { "Asia/Kamchatka" , 0x01C6C1 },
+ { "Asia/Karachi" , 0x01C8BA },
+ { "Asia/Kashgar" , 0x01C96F },
+ { "Asia/Kathmandu" , 0x01C9C4 },
+ { "Asia/Katmandu" , 0x01CA2A },
+ { "Asia/Khandyga" , 0x01CA90 },
+ { "Asia/Kolkata" , 0x01CCBA },
+ { "Asia/Krasnoyarsk" , 0x01CD33 },
+ { "Asia/Kuala_Lumpur" , 0x01CF20 },
+ { "Asia/Kuching" , 0x01CFDD },
+ { "Asia/Kuwait" , 0x01D0CB },
+ { "Asia/Macao" , 0x01D120 },
+ { "Asia/Macau" , 0x01D25B },
+ { "Asia/Magadan" , 0x01D396 },
+ { "Asia/Makassar" , 0x01D59A },
+ { "Asia/Manila" , 0x01D65F },
+ { "Asia/Muscat" , 0x01D6E4 },
+ { "Asia/Nicosia" , 0x01D739 },
+ { "Asia/Novokuznetsk" , 0x01DA21 },
+ { "Asia/Novosibirsk" , 0x01DC41 },
+ { "Asia/Omsk" , 0x01DE31 },
+ { "Asia/Oral" , 0x01E01D },
+ { "Asia/Phnom_Penh" , 0x01E1ED },
+ { "Asia/Pontianak" , 0x01E265 },
+ { "Asia/Pyongyang" , 0x01E327 },
+ { "Asia/Qatar" , 0x01E3B7 },
+ { "Asia/Qyzylorda" , 0x01E41D },
+ { "Asia/Rangoon" , 0x01E5F3 },
+ { "Asia/Riyadh" , 0x01E66B },
+ { "Asia/Saigon" , 0x01E6C0 },
+ { "Asia/Sakhalin" , 0x01E738 },
+ { "Asia/Samarkand" , 0x01E935 },
+ { "Asia/Seoul" , 0x01EA6B },
+ { "Asia/Shanghai" , 0x01EB32 },
+ { "Asia/Singapore" , 0x01EBDE },
+ { "Asia/Srednekolymsk" , 0x01EC95 },
+ { "Asia/Taipei" , 0x01EE95 },
+ { "Asia/Tashkent" , 0x01EFC6 },
+ { "Asia/Tbilisi" , 0x01F0F7 },
+ { "Asia/Tehran" , 0x01F2B1 },
+ { "Asia/Tel_Aviv" , 0x01F51F },
+ { "Asia/Thimbu" , 0x01F84E },
+ { "Asia/Thimphu" , 0x01F8B4 },
+ { "Asia/Tokyo" , 0x01F91A },
+ { "Asia/Ujung_Pandang" , 0x01F9A4 },
+ { "Asia/Ulaanbaatar" , 0x01FA21 },
+ { "Asia/Ulan_Bator" , 0x01FB7C },
+ { "Asia/Urumqi" , 0x01FCC9 },
+ { "Asia/Ust-Nera" , 0x01FD2B },
+ { "Asia/Vientiane" , 0x01FF3D },
+ { "Asia/Vladivostok" , 0x01FFB5 },
+ { "Asia/Yakutsk" , 0x02019F },
+ { "Asia/Yekaterinburg" , 0x020389 },
+ { "Asia/Yerevan" , 0x0205AA },
+ { "Atlantic/Azores" , 0x0207AA },
+ { "Atlantic/Bermuda" , 0x020CAD },
+ { "Atlantic/Canary" , 0x020F8E },
+ { "Atlantic/Cape_Verde" , 0x021264 },
+ { "Atlantic/Faeroe" , 0x0212DD },
+ { "Atlantic/Faroe" , 0x021581 },
+ { "Atlantic/Jan_Mayen" , 0x021825 },
+ { "Atlantic/Madeira" , 0x021B57 },
+ { "Atlantic/Reykjavik" , 0x022060 },
+ { "Atlantic/South_Georgia" , 0x022219 },
+ { "Atlantic/St_Helena" , 0x02242B },
+ { "Atlantic/Stanley" , 0x02225D },
+ { "Australia/ACT" , 0x022480 },
+ { "Australia/Adelaide" , 0x0227A3 },
+ { "Australia/Brisbane" , 0x022AD5 },
+ { "Australia/Broken_Hill" , 0x022BA2 },
+ { "Australia/Canberra" , 0x022EE6 },
+ { "Australia/Currie" , 0x023209 },
+ { "Australia/Darwin" , 0x023542 },
+ { "Australia/Eucla" , 0x0235CE },
+ { "Australia/Hobart" , 0x0236AA },
+ { "Australia/LHI" , 0x023A0E },
+ { "Australia/Lindeman" , 0x023CAF },
+ { "Australia/Lord_Howe" , 0x023D96 },
+ { "Australia/Melbourne" , 0x024047 },
+ { "Australia/North" , 0x024372 },
+ { "Australia/NSW" , 0x0243EC },
+ { "Australia/Perth" , 0x02470F },
+ { "Australia/Queensland" , 0x0247ED },
+ { "Australia/South" , 0x02489F },
+ { "Australia/Sydney" , 0x024BC2 },
+ { "Australia/Tasmania" , 0x024F05 },
+ { "Australia/Victoria" , 0x025250 },
+ { "Australia/West" , 0x025573 },
+ { "Australia/Yancowinna" , 0x02562F },
+ { "Brazil/Acre" , 0x025957 },
+ { "Brazil/DeNoronha" , 0x025A5B },
+ { "Brazil/East" , 0x025B7B },
+ { "Brazil/West" , 0x025E58 },
+ { "Canada/Atlantic" , 0x025F50 },
+ { "Canada/Central" , 0x026438 },
+ { "Canada/East-Saskatchewan" , 0x026D42 },
+ { "Canada/Eastern" , 0x026852 },
+ { "Canada/Mountain" , 0x026ECB },
+ { "Canada/Newfoundland" , 0x027241 },
+ { "Canada/Pacific" , 0x02776C },
+ { "Canada/Saskatchewan" , 0x027B85 },
+ { "Canada/Yukon" , 0x027D0E },
+ { "CET" , 0x028011 },
+ { "Chile/Continental" , 0x02831A },
+ { "Chile/EasterIsland" , 0x0286B5 },
+ { "CST6CDT" , 0x0289F7 },
+ { "Cuba" , 0x028D48 },
+ { "EET" , 0x0290BB },
+ { "Egypt" , 0x02936E },
+ { "Eire" , 0x029755 },
+ { "EST" , 0x029C66 },
+ { "EST5EDT" , 0x029CAA },
+ { "Etc/GMT" , 0x029FFB },
+ { "Etc/GMT+0" , 0x02A0C7 },
+ { "Etc/GMT+1" , 0x02A151 },
+ { "Etc/GMT+10" , 0x02A1DE },
+ { "Etc/GMT+11" , 0x02A26C },
+ { "Etc/GMT+12" , 0x02A2FA },
+ { "Etc/GMT+2" , 0x02A415 },
+ { "Etc/GMT+3" , 0x02A4A1 },
+ { "Etc/GMT+4" , 0x02A52D },
+ { "Etc/GMT+5" , 0x02A5B9 },
+ { "Etc/GMT+6" , 0x02A645 },
+ { "Etc/GMT+7" , 0x02A6D1 },
+ { "Etc/GMT+8" , 0x02A75D },
+ { "Etc/GMT+9" , 0x02A7E9 },
+ { "Etc/GMT-0" , 0x02A083 },
+ { "Etc/GMT-1" , 0x02A10B },
+ { "Etc/GMT-10" , 0x02A197 },
+ { "Etc/GMT-11" , 0x02A225 },
+ { "Etc/GMT-12" , 0x02A2B3 },
+ { "Etc/GMT-13" , 0x02A341 },
+ { "Etc/GMT-14" , 0x02A388 },
+ { "Etc/GMT-2" , 0x02A3CF },
+ { "Etc/GMT-3" , 0x02A45B },
+ { "Etc/GMT-4" , 0x02A4E7 },
+ { "Etc/GMT-5" , 0x02A573 },
+ { "Etc/GMT-6" , 0x02A5FF },
+ { "Etc/GMT-7" , 0x02A68B },
+ { "Etc/GMT-8" , 0x02A717 },
+ { "Etc/GMT-9" , 0x02A7A3 },
+ { "Etc/GMT0" , 0x02A03F },
+ { "Etc/Greenwich" , 0x02A82F },
+ { "Etc/UCT" , 0x02A873 },
+ { "Etc/Universal" , 0x02A8B7 },
+ { "Etc/UTC" , 0x02A8FB },
+ { "Etc/Zulu" , 0x02A93F },
+ { "Europe/Amsterdam" , 0x02A983 },
+ { "Europe/Andorra" , 0x02ADC1 },
+ { "Europe/Athens" , 0x02B03D },
+ { "Europe/Belfast" , 0x02B380 },
+ { "Europe/Belgrade" , 0x02B8B7 },
+ { "Europe/Berlin" , 0x02BB80 },
+ { "Europe/Bratislava" , 0x02BEE4 },
+ { "Europe/Brussels" , 0x02C216 },
+ { "Europe/Bucharest" , 0x02C64D },
+ { "Europe/Budapest" , 0x02C977 },
+ { "Europe/Busingen" , 0x02CCE0 },
+ { "Europe/Chisinau" , 0x02CF97 },
+ { "Europe/Copenhagen" , 0x02D325 },
+ { "Europe/Dublin" , 0x02D62F },
+ { "Europe/Gibraltar" , 0x02DB40 },
+ { "Europe/Guernsey" , 0x02DF97 },
+ { "Europe/Helsinki" , 0x02E4CE },
+ { "Europe/Isle_of_Man" , 0x02E784 },
+ { "Europe/Istanbul" , 0x02ECBB },
+ { "Europe/Jersey" , 0x02F0A8 },
+ { "Europe/Kaliningrad" , 0x02F5DF },
+ { "Europe/Kiev" , 0x02F84A },
+ { "Europe/Lisbon" , 0x02FB66 },
+ { "Europe/Ljubljana" , 0x03006A },
+ { "Europe/London" , 0x030333 },
+ { "Europe/Luxembourg" , 0x03086A },
+ { "Europe/Madrid" , 0x030CC0 },
+ { "Europe/Malta" , 0x031086 },
+ { "Europe/Mariehamn" , 0x03143F },
+ { "Europe/Minsk" , 0x0316F5 },
+ { "Europe/Monaco" , 0x031903 },
+ { "Europe/Moscow" , 0x031D3E },
+ { "Europe/Nicosia" , 0x031F98 },
+ { "Europe/Oslo" , 0x032280 },
+ { "Europe/Paris" , 0x0325B2 },
+ { "Europe/Podgorica" , 0x0329F8 },
+ { "Europe/Prague" , 0x032CC1 },
+ { "Europe/Riga" , 0x032FF3 },
+ { "Europe/Rome" , 0x033338 },
+ { "Europe/Samara" , 0x0336FB },
+ { "Europe/San_Marino" , 0x033964 },
+ { "Europe/Sarajevo" , 0x033D27 },
+ { "Europe/Simferopol" , 0x033FF0 },
+ { "Europe/Skopje" , 0x034241 },
+ { "Europe/Sofia" , 0x03450A },
+ { "Europe/Stockholm" , 0x034812 },
+ { "Europe/Tallinn" , 0x034AC1 },
+ { "Europe/Tirane" , 0x034DFB },
+ { "Europe/Tiraspol" , 0x035101 },
+ { "Europe/Uzhgorod" , 0x03548F },
+ { "Europe/Vaduz" , 0x0357A6 },
+ { "Europe/Vatican" , 0x035A55 },
+ { "Europe/Vienna" , 0x035E18 },
+ { "Europe/Vilnius" , 0x036145 },
+ { "Europe/Volgograd" , 0x036484 },
+ { "Europe/Warsaw" , 0x0366A5 },
+ { "Europe/Zagreb" , 0x036A86 },
+ { "Europe/Zaporozhye" , 0x036D4F },
+ { "Europe/Zurich" , 0x037090 },
+ { "Factory" , 0x03733F },
+ { "GB" , 0x0373B0 },
+ { "GB-Eire" , 0x0378E7 },
+ { "GMT" , 0x037E1E },
+ { "GMT+0" , 0x037EEA },
+ { "GMT-0" , 0x037EA6 },
+ { "GMT0" , 0x037E62 },
+ { "Greenwich" , 0x037F2E },
+ { "Hongkong" , 0x037F72 },
+ { "HST" , 0x038134 },
+ { "Iceland" , 0x038178 },
+ { "Indian/Antananarivo" , 0x038331 },
+ { "Indian/Chagos" , 0x0383A5 },
+ { "Indian/Christmas" , 0x038407 },
+ { "Indian/Cocos" , 0x03844B },
+ { "Indian/Comoro" , 0x03848F },
+ { "Indian/Kerguelen" , 0x0384E4 },
+ { "Indian/Mahe" , 0x038539 },
+ { "Indian/Maldives" , 0x03858E },
+ { "Indian/Mauritius" , 0x0385E3 },
+ { "Indian/Mayotte" , 0x038659 },
+ { "Indian/Reunion" , 0x0386AE },
+ { "Iran" , 0x038703 },
+ { "Israel" , 0x038971 },
+ { "Jamaica" , 0x038CA0 },
+ { "Japan" , 0x038D65 },
+ { "Kwajalein" , 0x038DEF },
+ { "Libya" , 0x038E52 },
+ { "MET" , 0x038F5B },
+ { "Mexico/BajaNorte" , 0x039264 },
+ { "Mexico/BajaSur" , 0x0395CD },
+ { "Mexico/General" , 0x039812 },
+ { "MST" , 0x039A70 },
+ { "MST7MDT" , 0x039AB4 },
+ { "Navajo" , 0x039E05 },
+ { "NZ" , 0x03A17E },
+ { "NZ-CHAT" , 0x03A4FC },
+ { "Pacific/Apia" , 0x03A7E0 },
+ { "Pacific/Auckland" , 0x03A97C },
+ { "Pacific/Chatham" , 0x03AD08 },
+ { "Pacific/Chuuk" , 0x03AFFB },
+ { "Pacific/Easter" , 0x03B054 },
+ { "Pacific/Efate" , 0x03B3A3 },
+ { "Pacific/Enderbury" , 0x03B469 },
+ { "Pacific/Fakaofo" , 0x03B4D7 },
+ { "Pacific/Fiji" , 0x03B528 },
+ { "Pacific/Funafuti" , 0x03B6BB },
+ { "Pacific/Galapagos" , 0x03B6FF },
+ { "Pacific/Gambier" , 0x03B777 },
+ { "Pacific/Guadalcanal" , 0x03B7DC },
+ { "Pacific/Guam" , 0x03B831 },
+ { "Pacific/Honolulu" , 0x03B887 },
+ { "Pacific/Johnston" , 0x03B8FE },
+ { "Pacific/Kiritimati" , 0x03B97D },
+ { "Pacific/Kosrae" , 0x03B9E8 },
+ { "Pacific/Kwajalein" , 0x03BA45 },
+ { "Pacific/Majuro" , 0x03BAB1 },
+ { "Pacific/Marquesas" , 0x03BB10 },
+ { "Pacific/Midway" , 0x03BB77 },
+ { "Pacific/Nauru" , 0x03BC01 },
+ { "Pacific/Niue" , 0x03BC79 },
+ { "Pacific/Norfolk" , 0x03BCD7 },
+ { "Pacific/Noumea" , 0x03BD2C },
+ { "Pacific/Pago_Pago" , 0x03BDBC },
+ { "Pacific/Palau" , 0x03BE33 },
+ { "Pacific/Pitcairn" , 0x03BE77 },
+ { "Pacific/Pohnpei" , 0x03BECC },
+ { "Pacific/Ponape" , 0x03BF21 },
+ { "Pacific/Port_Moresby" , 0x03BF66 },
+ { "Pacific/Rarotonga" , 0x03BFAA },
+ { "Pacific/Saipan" , 0x03C086 },
+ { "Pacific/Samoa" , 0x03C0E9 },
+ { "Pacific/Tahiti" , 0x03C160 },
+ { "Pacific/Tarawa" , 0x03C1C5 },
+ { "Pacific/Tongatapu" , 0x03C219 },
+ { "Pacific/Truk" , 0x03C2A5 },
+ { "Pacific/Wake" , 0x03C2EA },
+ { "Pacific/Wallis" , 0x03C33A },
+ { "Pacific/Yap" , 0x03C37E },
+ { "Poland" , 0x03C3C3 },
+ { "Portugal" , 0x03C7A4 },
+ { "PRC" , 0x03CCA0 },
+ { "PST8PDT" , 0x03CD40 },
+ { "ROC" , 0x03D091 },
+ { "ROK" , 0x03D1C2 },
+ { "Singapore" , 0x03D289 },
+ { "Turkey" , 0x03D340 },
+ { "UCT" , 0x03D72D },
+ { "Universal" , 0x03D771 },
+ { "US/Alaska" , 0x03D7B5 },
+ { "US/Aleutian" , 0x03DB1E },
+ { "US/Arizona" , 0x03DE84 },
+ { "US/Central" , 0x03DF12 },
+ { "US/East-Indiana" , 0x03E91C },
+ { "US/Eastern" , 0x03E41D },
+ { "US/Hawaii" , 0x03EB86 },
+ { "US/Indiana-Starke" , 0x03EBF7 },
+ { "US/Michigan" , 0x03EF68 },
+ { "US/Mountain" , 0x03F29F },
+ { "US/Pacific" , 0x03F618 },
+ { "US/Pacific-New" , 0x03FA1D },
+ { "US/Samoa" , 0x03FE22 },
+ { "UTC" , 0x03FE99 },
+ { "W-SU" , 0x040190 },
+ { "WET" , 0x03FEDD },
+ { "Zulu" , 0x0403D3 },
};
/* This is a generated file, do not modify */
-const unsigned char timelib_timezone_db_data_builtin[263151] = {
+const unsigned char timelib_timezone_db_data_builtin[263191] = {
/* Africa/Abidjan */
@@ -698,8 +698,8 @@ const unsigned char timelib_timezone_db_data_builtin[263151] = {
/* Africa/Blantyre */
0x50, 0x48, 0x50, 0x31, 0x01, 0x4D, 0x57, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
-0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x08, 0x82, 0x46, 0xC3, 0xB0,
-0x01, 0x00, 0x00, 0x20, 0xD0, 0x00, 0x00, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x04, 0x4C, 0x4D, 0x54,
+0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x08, 0x82, 0x46, 0xC5, 0xF4,
+0x01, 0x00, 0x00, 0x1E, 0x8C, 0x00, 0x00, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x04, 0x4C, 0x4D, 0x54,
0x00, 0x43, 0x41, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x71, 0x3E, 0xE2, 0x01, 0x48, 0x10,
0x60, 0x00, 0x00, 0x00, 0x00,
@@ -713,10 +713,11 @@ const unsigned char timelib_timezone_db_data_builtin[263151] = {
/* Africa/Bujumbura */
0x50, 0x48, 0x50, 0x31, 0x01, 0x42, 0x49, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00,
-0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x1C, 0x20,
-0x00, 0x00, 0x43, 0x41, 0x54, 0x00, 0x00, 0x00, 0x00, 0x84, 0x2A, 0xA2, 0x01, 0x3F, 0x77, 0xDA,
-0x00, 0x00, 0x00, 0x00,
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
+0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x08, 0x82, 0x46, 0xC5, 0xF4,
+0x01, 0x00, 0x00, 0x1E, 0x8C, 0x00, 0x00, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x04, 0x4C, 0x4D, 0x54,
+0x00, 0x43, 0x41, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x84, 0x2A, 0xA2, 0x01, 0x3F, 0x77,
+0xDA, 0x00, 0x00, 0x00, 0x00,
/* Africa/Cairo */
0x50, 0x48, 0x50, 0x31, 0x01, 0x45, 0x47, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
@@ -963,18 +964,17 @@ const unsigned char timelib_timezone_db_data_builtin[263151] = {
/* Africa/Gaborone */
0x50, 0x48, 0x50, 0x31, 0x01, 0x42, 0x57, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00,
-0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x0E, 0x82, 0x46, 0xCF, 0x68,
-0xCE, 0x8E, 0x6E, 0x80, 0xCF, 0x7E, 0x51, 0x70, 0x01, 0x02, 0x01, 0x00, 0x00, 0x15, 0x18, 0x00,
-0x00, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x05, 0x00, 0x00, 0x2A, 0x30, 0x01, 0x09, 0x53, 0x41, 0x53,
-0x54, 0x00, 0x43, 0x41, 0x54, 0x00, 0x43, 0x41, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-0x00, 0x00, 0x63, 0xB7, 0x57, 0x01, 0x3A, 0x34, 0x32, 0x00, 0x00, 0x00, 0x00,
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
+0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x08, 0x82, 0x46, 0xC5, 0xF4,
+0x01, 0x00, 0x00, 0x1E, 0x8C, 0x00, 0x00, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x04, 0x4C, 0x4D, 0x54,
+0x00, 0x43, 0x41, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x63, 0xB7, 0x57, 0x01, 0x3A, 0x34,
+0x32, 0x00, 0x00, 0x00, 0x00,
/* Africa/Harare */
0x50, 0x48, 0x50, 0x31, 0x01, 0x5A, 0x57, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
-0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x08, 0x82, 0x46, 0xC7, 0x64,
-0x01, 0x00, 0x00, 0x1D, 0x1C, 0x00, 0x00, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x04, 0x4C, 0x4D, 0x54,
+0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x08, 0x82, 0x46, 0xC5, 0xF4,
+0x01, 0x00, 0x00, 0x1E, 0x8C, 0x00, 0x00, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x04, 0x4C, 0x4D, 0x54,
0x00, 0x43, 0x41, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x6E, 0x1E, 0x1A, 0x01, 0x42, 0x09,
0x68, 0x00, 0x00, 0x00, 0x00,
@@ -1040,8 +1040,8 @@ const unsigned char timelib_timezone_db_data_builtin[263151] = {
/* Africa/Kigali */
0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x57, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
-0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x08, 0xBE, 0xF1, 0x0E, 0x50,
-0x01, 0x00, 0x00, 0x1C, 0x30, 0x00, 0x00, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x04, 0x4C, 0x4D, 0x54,
+0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x08, 0x82, 0x46, 0xC5, 0xF4,
+0x01, 0x00, 0x00, 0x1E, 0x8C, 0x00, 0x00, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x04, 0x4C, 0x4D, 0x54,
0x00, 0x43, 0x41, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x86, 0x5A, 0x88, 0x01, 0x40, 0x89,
0x4A, 0x00, 0x00, 0x00, 0x00,
@@ -1088,17 +1088,18 @@ const unsigned char timelib_timezone_db_data_builtin[263151] = {
/* Africa/Lubumbashi */
0x50, 0x48, 0x50, 0x31, 0x01, 0x43, 0x44, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00,
-0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x1C, 0x20,
-0x00, 0x00, 0x43, 0x41, 0x54, 0x00, 0x00, 0x00, 0x00, 0x77, 0x86, 0xF5, 0x01, 0x3C, 0x91, 0xAA,
-0x00, 0x00, 0x00, 0x17, 0x65, 0x61, 0x73, 0x74, 0x20, 0x44, 0x65, 0x6D, 0x2E, 0x20, 0x52, 0x65,
-0x70, 0x2E, 0x20, 0x6F, 0x66, 0x20, 0x43, 0x6F, 0x6E, 0x67, 0x6F,
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
+0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x08, 0x82, 0x46, 0xC5, 0xF4,
+0x01, 0x00, 0x00, 0x1E, 0x8C, 0x00, 0x00, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x04, 0x4C, 0x4D, 0x54,
+0x00, 0x43, 0x41, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x77, 0x86, 0xF5, 0x01, 0x3C, 0x91,
+0xAA, 0x00, 0x00, 0x00, 0x17, 0x65, 0x61, 0x73, 0x74, 0x20, 0x44, 0x65, 0x6D, 0x2E, 0x20, 0x52,
+0x65, 0x70, 0x2E, 0x20, 0x6F, 0x66, 0x20, 0x43, 0x6F, 0x6E, 0x67, 0x6F,
/* Africa/Lusaka */
0x50, 0x48, 0x50, 0x31, 0x01, 0x5A, 0x4D, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
-0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x08, 0x82, 0x46, 0xC9, 0xFC,
-0x01, 0x00, 0x00, 0x1A, 0x84, 0x00, 0x00, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x04, 0x4C, 0x4D, 0x54,
+0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x08, 0x82, 0x46, 0xC5, 0xF4,
+0x01, 0x00, 0x00, 0x1E, 0x8C, 0x00, 0x00, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x04, 0x4C, 0x4D, 0x54,
0x00, 0x43, 0x41, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x71, 0xCE, 0x1D, 0x01, 0x3D, 0xD0,
0xAD, 0x00, 0x00, 0x00, 0x00,
@@ -1121,19 +1122,20 @@ const unsigned char timelib_timezone_db_data_builtin[263151] = {
/* Africa/Maseru */
0x50, 0x48, 0x50, 0x31, 0x01, 0x4C, 0x53, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00,
-0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x09, 0x82, 0x46, 0xCA, 0xB8,
-0xCE, 0x8E, 0x6E, 0x80, 0xCF, 0x7E, 0x51, 0x70, 0x01, 0x02, 0x01, 0x00, 0x00, 0x19, 0xC8, 0x00,
-0x00, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x04, 0x00, 0x00, 0x2A, 0x30, 0x01, 0x04, 0x4C, 0x4D, 0x54,
-0x00, 0x53, 0x41, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x5C, 0x5D, 0xD5,
-0x01, 0x3C, 0x9E, 0xB0, 0x00, 0x00, 0x00, 0x00,
+0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x05, 0x82, 0x46, 0xCF, 0x68,
+0xCC, 0xAE, 0x8C, 0x80, 0xCD, 0x9E, 0x6F, 0x70, 0xCE, 0x8E, 0x6E, 0x80, 0xCF, 0x7E, 0x51, 0x70,
+0x02, 0x01, 0x02, 0x01, 0x02, 0x00, 0x00, 0x15, 0x18, 0x00, 0x00, 0x00, 0x00, 0x2A, 0x30, 0x01,
+0x00, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x00, 0x53, 0x41, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00,
+0x00, 0x00, 0x00, 0x5C, 0x5D, 0xD5, 0x01, 0x3C, 0x9E, 0xB0, 0x00, 0x00, 0x00, 0x00,
/* Africa/Mbabane */
0x50, 0x48, 0x50, 0x31, 0x01, 0x53, 0x5A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
-0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x09, 0x82, 0x46, 0xC7, 0x58,
-0x01, 0x00, 0x00, 0x1D, 0x28, 0x00, 0x00, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x04, 0x4C, 0x4D, 0x54,
-0x00, 0x53, 0x41, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x61, 0x32, 0xD0, 0x01, 0x42,
-0x1C, 0xF0, 0x00, 0x00, 0x00, 0x00,
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00,
+0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x05, 0x82, 0x46, 0xCF, 0x68,
+0xCC, 0xAE, 0x8C, 0x80, 0xCD, 0x9E, 0x6F, 0x70, 0xCE, 0x8E, 0x6E, 0x80, 0xCF, 0x7E, 0x51, 0x70,
+0x02, 0x01, 0x02, 0x01, 0x02, 0x00, 0x00, 0x15, 0x18, 0x00, 0x00, 0x00, 0x00, 0x2A, 0x30, 0x01,
+0x00, 0x00, 0x00, 0x1C, 0x20, 0x00, 0x00, 0x53, 0x41, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00,
+0x00, 0x00, 0x00, 0x61, 0x32, 0xD0, 0x01, 0x42, 0x1C, 0xF0, 0x00, 0x00, 0x00, 0x00,
/* Africa/Mogadishu */
0x50, 0x48, 0x50, 0x31, 0x01, 0x53, 0x4F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
@@ -4056,7 +4058,7 @@ const unsigned char timelib_timezone_db_data_builtin[263151] = {
0x50, 0x48, 0x50, 0x31, 0x01, 0x4A, 0x4D, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x0C, 0x93, 0x0F, 0xB4, 0xFF,
-0x08, 0x20, 0xC1, 0x70, 0x09, 0x10, 0xA4, 0x60, 0x09, 0xAD, 0x94, 0xF0, 0x0A, 0xF0, 0x86, 0x60,
+0x07, 0x8D, 0x19, 0x70, 0x09, 0x10, 0xA4, 0x60, 0x09, 0xAD, 0x94, 0xF0, 0x0A, 0xF0, 0x86, 0x60,
0x0B, 0xE0, 0x85, 0x70, 0x0C, 0xD9, 0xA2, 0xE0, 0x0D, 0xC0, 0x67, 0x70, 0x0E, 0xB9, 0x84, 0xE0,
0x0F, 0xA9, 0x83, 0xF0, 0x10, 0x99, 0x66, 0xE0, 0x11, 0x89, 0x65, 0xF0, 0x12, 0x79, 0x48, 0xE0,
0x13, 0x69, 0x47, 0xF0, 0x14, 0x59, 0x2A, 0xE0, 0x15, 0x49, 0x29, 0xF0, 0x16, 0x39, 0x0C, 0xE0,
@@ -8909,7 +8911,7 @@ const unsigned char timelib_timezone_db_data_builtin[263151] = {
/* Asia/Novokuznetsk */
0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0B, 0x00, 0x00, 0x00, 0x0B, 0x00, 0x00, 0x00, 0x00,
-0x00, 0x00, 0x00, 0x41, 0x00, 0x00, 0x00, 0x0B, 0x00, 0x00, 0x00, 0x1A, 0xA1, 0xF9, 0x13, 0x40,
+0x00, 0x00, 0x00, 0x41, 0x00, 0x00, 0x00, 0x0B, 0x00, 0x00, 0x00, 0x1A, 0xAA, 0x18, 0x20, 0xC0,
0xB5, 0xA3, 0xE1, 0x20, 0x15, 0x27, 0x6F, 0x90, 0x16, 0x18, 0xA4, 0x00, 0x17, 0x08, 0xA3, 0x10,
0x17, 0xF9, 0xD7, 0x80, 0x18, 0xE9, 0xD6, 0x90, 0x19, 0xDB, 0x0B, 0x00, 0x1A, 0xCC, 0x5B, 0x90,
0x1B, 0xBC, 0x68, 0xB0, 0x1C, 0xAC, 0x59, 0xB0, 0x1D, 0x9C, 0x4A, 0xB0, 0x1E, 0x8C, 0x3B, 0xB0,
@@ -8934,7 +8936,7 @@ const unsigned char timelib_timezone_db_data_builtin[263151] = {
0x80, 0x01, 0x09, 0x00, 0x00, 0x62, 0x70, 0x00, 0x04, 0x00, 0x00, 0x62, 0x70, 0x00, 0x04, 0x00,
0x00, 0x70, 0x80, 0x01, 0x09, 0x00, 0x00, 0x62, 0x70, 0x01, 0x09, 0x00, 0x00, 0x54, 0x60, 0x00,
0x04, 0x00, 0x00, 0x62, 0x70, 0x01, 0x0F, 0x00, 0x00, 0x54, 0x60, 0x00, 0x15, 0x00, 0x00, 0x62,
-0x70, 0x00, 0x15, 0x4E, 0x4D, 0x54, 0x00, 0x4B, 0x52, 0x41, 0x54, 0x00, 0x4B, 0x52, 0x41, 0x53,
+0x70, 0x00, 0x15, 0x4C, 0x4D, 0x54, 0x00, 0x4B, 0x52, 0x41, 0x54, 0x00, 0x4B, 0x52, 0x41, 0x53,
0x54, 0x00, 0x4E, 0x4F, 0x56, 0x53, 0x54, 0x00, 0x4E, 0x4F, 0x56, 0x54, 0x00, 0x00, 0x00, 0x00,
0x00, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0xDB, 0x58, 0x58, 0x01, 0x97, 0x96, 0x72, 0x00, 0x00, 0x00, 0x31, 0x4D,
@@ -16412,7 +16414,7 @@ const unsigned char timelib_timezone_db_data_builtin[263151] = {
0x50, 0x48, 0x50, 0x31, 0x00, 0x3F, 0x3F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x15, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x0C, 0x93, 0x0F, 0xB4, 0xFF,
-0x08, 0x20, 0xC1, 0x70, 0x09, 0x10, 0xA4, 0x60, 0x09, 0xAD, 0x94, 0xF0, 0x0A, 0xF0, 0x86, 0x60,
+0x07, 0x8D, 0x19, 0x70, 0x09, 0x10, 0xA4, 0x60, 0x09, 0xAD, 0x94, 0xF0, 0x0A, 0xF0, 0x86, 0x60,
0x0B, 0xE0, 0x85, 0x70, 0x0C, 0xD9, 0xA2, 0xE0, 0x0D, 0xC0, 0x67, 0x70, 0x0E, 0xB9, 0x84, 0xE0,
0x0F, 0xA9, 0x83, 0xF0, 0x10, 0x99, 0x66, 0xE0, 0x11, 0x89, 0x65, 0xF0, 0x12, 0x79, 0x48, 0xE0,
0x13, 0x69, 0x47, 0xF0, 0x14, 0x59, 0x2A, 0xE0, 0x15, 0x49, 0x29, 0xF0, 0x16, 0x39, 0x0C, 0xE0,
@@ -18530,4 +18532,4 @@ const unsigned char timelib_timezone_db_data_builtin[263151] = {
0x00, 0x00, 0x55, 0x54, 0x43, 0x00, 0x00, 0x00, 0x00, 0x89, 0x54, 0x40, 0x01, 0x12, 0xA8, 0x80,
0x00, 0x00, 0x00, 0x00, };
-const timelib_tzdb timezonedb_builtin = { "2014.7", 582, timezonedb_idx_builtin, timelib_timezone_db_data_builtin };
+const timelib_tzdb timezonedb_builtin = { "2014.8", 582, timezonedb_idx_builtin, timelib_timezone_db_data_builtin };
diff --git a/ext/date/lib/tm2unixtime.c b/ext/date/lib/tm2unixtime.c
index 7231dff093..40fbd6805a 100644
--- a/ext/date/lib/tm2unixtime.c
+++ b/ext/date/lib/tm2unixtime.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/date/lib/unixtime2tm.c b/ext/date/lib/unixtime2tm.c
index 9870313fbc..93c4126d14 100644
--- a/ext/date/lib/unixtime2tm.c
+++ b/ext/date/lib/unixtime2tm.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/date/php_date.c b/ext/date/php_date.c
index cf3f6214a5..360c6d3f67 100644
--- a/ext/date/php_date.c
+++ b/ext/date/php_date.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -999,7 +999,7 @@ PHPAPI timelib_tzinfo *get_timezone_info(TSRMLS_D)
/* {{{ date() and gmdate() data */
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
static char *mon_full_names[] = {
"January", "February", "March", "April",
@@ -2220,7 +2220,7 @@ static HashTable *date_object_get_properties(zval *object TSRMLS_DC) /* {{{ */
abs(utc_offset / 60),
abs((utc_offset % 60)));
- ZVAL_STR(&zv, tmpstr);
+ ZVAL_NEW_STR(&zv, tmpstr);
}
break;
case TIMELIB_ZONETYPE_ABBR:
@@ -2312,7 +2312,7 @@ static HashTable *date_object_get_properties_timezone(zval *object TSRMLS_DC) /*
abs(tzobj->tzi.utc_offset / 60),
abs((tzobj->tzi.utc_offset % 60)));
- ZVAL_STR(&zv, tmpstr);
+ ZVAL_NEW_STR(&zv, tmpstr);
}
break;
case TIMELIB_ZONETYPE_ABBR:
@@ -4496,12 +4496,12 @@ PHP_FUNCTION(timezone_abbreviations_list)
do {
array_init(&element);
- add_assoc_bool(&element, "dst", entry->type);
- add_assoc_long(&element, "offset", entry->gmtoffset);
+ add_assoc_bool_ex(&element, "dst", sizeof("dst") -1, entry->type);
+ add_assoc_long_ex(&element, "offset", sizeof("offset") - 1, entry->gmtoffset);
if (entry->full_tz_name) {
- add_assoc_string(&element, "timezone_id", entry->full_tz_name);
+ add_assoc_string_ex(&element, "timezone_id", sizeof("timezone_id") - 1, entry->full_tz_name);
} else {
- add_assoc_null(&element, "timezone_id");
+ add_assoc_null_ex(&element, "timezone_id", sizeof("timezone_id") - 1);
}
abbr_array_p = zend_hash_str_find(HASH_OF(return_value), entry->name, strlen(entry->name));
diff --git a/ext/date/php_date.h b/ext/date/php_date.h
index ad82666cd7..aa46aa1b6c 100644
--- a/ext/date/php_date.h
+++ b/ext/date/php_date.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/date/tests/bug67118.phpt b/ext/date/tests/bug67118.phpt
index 19b5914aa3..332142856e 100644
--- a/ext/date/tests/bug67118.phpt
+++ b/ext/date/tests/bug67118.phpt
@@ -23,4 +23,5 @@ class mydt extends datetime
new mydt("Funktionsansvarig rådgivning och juridik", "UTC");
?>
--EXPECTF--
-Fatal error: Call to a member function format() on null in %sbug67118.php on line %d
+Warning: DateTime::format(): The DateTime object has not been correctly initialized by its constructor in %s on line %d
+Bad date
diff --git a/ext/date/tests/bug67118_2.phpt b/ext/date/tests/bug67118_2.phpt
index 368d4d9401..9b6f545525 100644
--- a/ext/date/tests/bug67118_2.phpt
+++ b/ext/date/tests/bug67118_2.phpt
@@ -24,5 +24,12 @@ Done
--EXPECTF--
First try
Second try
-NULL
-Done \ No newline at end of file
+object(Foo)#1 (3) {
+ ["date"]=>
+ string(26) "2007-09-12 15:49:12.000000"
+ ["timezone_type"]=>
+ int(3)
+ ["timezone"]=>
+ string(3) "UTC"
+}
+Done
diff --git a/ext/dba/dba.c b/ext/dba/dba.c
index 6bb98e24b5..de4ea4c464 100644
--- a/ext/dba/dba.c
+++ b/ext/dba/dba.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -470,19 +470,19 @@ ZEND_INI_MH(OnUpdateDefaultHandler)
{
dba_handler *hptr;
- if (!strlen(new_value)) {
+ if (!new_value->len) {
DBA_G(default_hptr) = NULL;
- return OnUpdateString(entry, new_value, new_value_length, mh_arg1, mh_arg2, mh_arg3, stage TSRMLS_CC);
+ return OnUpdateString(entry, new_value, mh_arg1, mh_arg2, mh_arg3, stage TSRMLS_CC);
}
- for (hptr = handler; hptr->name && strcasecmp(hptr->name, new_value); hptr++);
+ for (hptr = handler; hptr->name && strcasecmp(hptr->name, new_value->val); hptr++);
if (!hptr->name) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "No such handler: %s", new_value);
+ php_error_docref(NULL TSRMLS_CC, E_WARNING, "No such handler: %s", new_value->val);
return FAILURE;
}
DBA_G(default_hptr) = hptr;
- return OnUpdateString(entry, new_value, new_value_length, mh_arg1, mh_arg2, mh_arg3, stage TSRMLS_CC);
+ return OnUpdateString(entry, new_value, mh_arg1, mh_arg2, mh_arg3, stage TSRMLS_CC);
}
PHP_INI_BEGIN()
@@ -519,7 +519,7 @@ PHP_MSHUTDOWN_FUNCTION(dba)
}
/* }}} */
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
/* {{{ PHP_MINFO_FUNCTION
*/
diff --git a/ext/dba/dba.dsp b/ext/dba/dba.dsp
deleted file mode 100644
index ddfd1485a9..0000000000
--- a/ext/dba/dba.dsp
+++ /dev/null
@@ -1,213 +0,0 @@
-# Microsoft Developer Studio Project File - Name="dba" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=dba - Win32 Debug_TS Berkeley DB3
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "dba.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "dba.mak" CFG="dba - Win32 Debug_TS Berkeley DB3"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "dba - Win32 Release_TS Berkeley DB3" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "dba - Win32 Debug_TS Berkeley DB3" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "dba - Win32 Release_TS Berkeley DB3"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /D ZEND_DEBUG=0 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "COMPILE_DL_DBA" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_DBA=1 /D DBA_DB3=1 /D DB3_INCLUDE_FILE="db.h" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /D ZEND_DEBUG=0 /D DBA_DB3=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "COMPILE_DL_DBA" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_DBA=1 /D DBA_FLATFILE=1 /D DBA_CDB=1 /D DBA_CDB_MAKE=1 /D DBA_CDB_BUILTIN=1 /D DBA_INIFILE=1 /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "NDEBUG"
-# ADD RSC /l 0x407 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 php5ts.lib libdb31s.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_dba.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-# ADD LINK32 php5ts.lib libdb31s.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_dba.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-
-!ELSEIF "$(CFG)" == "dba - Win32 Debug_TS Berkeley DB3"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "COMPILE_DL_DBA" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_DBA=1 /D "DBA_DB3" /D DB3_INCLUDE_FILE="db.h" /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /D ZEND_DEBUG=1 /D "DBA_DB3" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "COMPILE_DL_DBA" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_DBA=1 /D DBA_FLATFILE=1 /D DBA_CDB=1 /D DBA_CDB_MAKE=1 /D DBA_CDB_BUILTIN=1 /D DBA_INIFILE=1 /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "_DEBUG"
-# ADD RSC /l 0x407 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 php5ts_debug.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_dba.dll" /pdbtype:sept /libpath:"..\..\Debug_TS"
-# ADD LINK32 php5ts_debug.lib libdb31s.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_dba.dll" /pdbtype:sept /libpath:"..\..\Debug_TS"
-
-!ENDIF
-
-# Begin Target
-
-# Name "dba - Win32 Release_TS Berkeley DB3"
-# Name "dba - Win32 Debug_TS Berkeley DB3"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\libcdb\cdb.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libcdb\cdb_make.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\dba.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\dba_cdb.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\dba_db2.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\dba_db3.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\dba_dbm.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\dba_flatfile.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\dba_gdbm.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\dba_inifile.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\dba_ndbm.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libflatfile\flatfile.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libinifile\inifile.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libcdb\uint32.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\libcdb\cdb.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libcdb\cdb_make.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libflatfile\flatfile.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_cdb.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_db2.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_db3.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_dba.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_dbm.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_flatfile.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_gdbm.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_inifile.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_ndbm.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libcdb\uint32.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libinifile\inifile.h
-# End Source File
-# End Group
-# End Target
-# End Project
diff --git a/ext/dba/dba_cdb.c b/ext/dba/dba_cdb.c
index 075aedb0c1..17419dcf2e 100644
--- a/ext/dba/dba_cdb.c
+++ b/ext/dba/dba_cdb.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/dba_db1.c b/ext/dba/dba_db1.c
index 8ee5d95f22..66fd58b151 100644
--- a/ext/dba/dba_db1.c
+++ b/ext/dba/dba_db1.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/dba_db2.c b/ext/dba/dba_db2.c
index 60aa37f93a..6643eebcde 100644
--- a/ext/dba/dba_db2.c
+++ b/ext/dba/dba_db2.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/dba_db3.c b/ext/dba/dba_db3.c
index 95a1e51fe0..3f31222d9e 100644
--- a/ext/dba/dba_db3.c
+++ b/ext/dba/dba_db3.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/dba_db4.c b/ext/dba/dba_db4.c
index 94a6c95e81..a9752a7bf6 100644
--- a/ext/dba/dba_db4.c
+++ b/ext/dba/dba_db4.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/dba_dbm.c b/ext/dba/dba_dbm.c
index f65a79bcc7..b369f11c70 100644
--- a/ext/dba/dba_dbm.c
+++ b/ext/dba/dba_dbm.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/dba_flatfile.c b/ext/dba/dba_flatfile.c
index ee8eefa652..9be6e9be18 100644
--- a/ext/dba/dba_flatfile.c
+++ b/ext/dba/dba_flatfile.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/dba_gdbm.c b/ext/dba/dba_gdbm.c
index d2c4a2f367..bea2f4cf58 100644
--- a/ext/dba/dba_gdbm.c
+++ b/ext/dba/dba_gdbm.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/dba_inifile.c b/ext/dba/dba_inifile.c
index 6067e99154..aaae690344 100644
--- a/ext/dba/dba_inifile.c
+++ b/ext/dba/dba_inifile.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/dba_ndbm.c b/ext/dba/dba_ndbm.c
index 417446759c..f7b33efd3f 100644
--- a/ext/dba/dba_ndbm.c
+++ b/ext/dba/dba_ndbm.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/dba_qdbm.c b/ext/dba/dba_qdbm.c
index a32b7e9e97..023e5e9b27 100644
--- a/ext/dba/dba_qdbm.c
+++ b/ext/dba/dba_qdbm.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/dba_tcadb.c b/ext/dba/dba_tcadb.c
index 341e99fed6..99c10c2f07 100644
--- a/ext/dba/dba_tcadb.c
+++ b/ext/dba/dba_tcadb.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/libcdb/cdb.c b/ext/dba/libcdb/cdb.c
index d8c58372ba..c8caf8b8f2 100644
--- a/ext/dba/libcdb/cdb.c
+++ b/ext/dba/libcdb/cdb.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/libcdb/cdb.h b/ext/dba/libcdb/cdb.h
index c6ffd17949..4b4a7ff2ff 100644
--- a/ext/dba/libcdb/cdb.h
+++ b/ext/dba/libcdb/cdb.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/libcdb/cdb_make.c b/ext/dba/libcdb/cdb_make.c
index 2813336b40..b6236f085e 100644
--- a/ext/dba/libcdb/cdb_make.c
+++ b/ext/dba/libcdb/cdb_make.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/libcdb/cdb_make.h b/ext/dba/libcdb/cdb_make.h
index d43fceb6d8..d33fcb15da 100644
--- a/ext/dba/libcdb/cdb_make.h
+++ b/ext/dba/libcdb/cdb_make.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/libcdb/uint32.c b/ext/dba/libcdb/uint32.c
index d8152d5015..76e1bbeaf2 100644
--- a/ext/dba/libcdb/uint32.c
+++ b/ext/dba/libcdb/uint32.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/libcdb/uint32.h b/ext/dba/libcdb/uint32.h
index b0e0b44002..5390291953 100644
--- a/ext/dba/libcdb/uint32.h
+++ b/ext/dba/libcdb/uint32.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/libflatfile/flatfile.c b/ext/dba/libflatfile/flatfile.c
index a1fce218ab..8eae2d2508 100644
--- a/ext/dba/libflatfile/flatfile.c
+++ b/ext/dba/libflatfile/flatfile.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/libflatfile/flatfile.h b/ext/dba/libflatfile/flatfile.h
index 7e9b1796cd..2cd8db3521 100644
--- a/ext/dba/libflatfile/flatfile.h
+++ b/ext/dba/libflatfile/flatfile.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/libinifile/inifile.c b/ext/dba/libinifile/inifile.c
index 218037ebe3..6b64872649 100644
--- a/ext/dba/libinifile/inifile.c
+++ b/ext/dba/libinifile/inifile.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/libinifile/inifile.h b/ext/dba/libinifile/inifile.h
index e41dac0ca4..9de43b62f5 100644
--- a/ext/dba/libinifile/inifile.h
+++ b/ext/dba/libinifile/inifile.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/php_dba.h b/ext/dba/php_dba.h
index d4d4c62c4a..d19000cf0f 100644
--- a/ext/dba/php_dba.h
+++ b/ext/dba/php_dba.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dba/php_tcadb.h b/ext/dba/php_tcadb.h
index b718a172f8..209830a94c 100644
--- a/ext/dba/php_tcadb.h
+++ b/ext/dba/php_tcadb.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/attr.c b/ext/dom/attr.c
index b650774378..7cef0230a4 100644
--- a/ext/dom/attr.c
+++ b/ext/dom/attr.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/cdatasection.c b/ext/dom/cdatasection.c
index a126cec573..82af257c0a 100644
--- a/ext/dom/cdatasection.c
+++ b/ext/dom/cdatasection.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/characterdata.c b/ext/dom/characterdata.c
index ea954f8905..aee54bb3d2 100644
--- a/ext/dom/characterdata.c
+++ b/ext/dom/characterdata.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/comment.c b/ext/dom/comment.c
index 050c3abf70..9015586fd9 100644
--- a/ext/dom/comment.c
+++ b/ext/dom/comment.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/document.c b/ext/dom/document.c
index a63004d705..133572af3f 100644
--- a/ext/dom/document.c
+++ b/ext/dom/document.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/documentfragment.c b/ext/dom/documentfragment.c
index ac2c8e4ea8..d3055214f6 100644
--- a/ext/dom/documentfragment.c
+++ b/ext/dom/documentfragment.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/documenttype.c b/ext/dom/documenttype.c
index 1193ed44d5..08b33242b1 100644
--- a/ext/dom/documenttype.c
+++ b/ext/dom/documenttype.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -204,7 +204,7 @@ int dom_documenttype_internal_subset_read(dom_object *obj, zval *retval TSRMLS_D
if (ret_buf.s) {
smart_str_0(&ret_buf);
- ZVAL_STR(retval, ret_buf.s);
+ ZVAL_NEW_STR(retval, ret_buf.s);
return SUCCESS;
}
}
diff --git a/ext/dom/dom.dsp b/ext/dom/dom.dsp
deleted file mode 100644
index f2ae5b1a76..0000000000
--- a/ext/dom/dom.dsp
+++ /dev/null
@@ -1,250 +0,0 @@
-# Microsoft Developer Studio Project File - Name="dom" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=dom - Win32 Release_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "dom.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "dom.mak" CFG="dom - Win32 Release_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "dom - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "dom - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "dom - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\..\Zend" /I "..\..\..\TSRM" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "COMPILE_DL_DOM" /D ZTS=1 /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /D ZEND_DEBUG=0 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "DOM_EXPORTS" /D "COMPILE_DL_DOM" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_DOM=1 /D "LIBXML_THREAD_ENABLED" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib /nologo /dll /machine:I386
-# ADD LINK32 wsock32.lib php5ts.lib resolv.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /incremental:yes /machine:I386 /out:"..\..\Release_TS/php_dom.dll" /implib:"..\..\Release_TS/php_dom.lib" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline" /libpath:"..\..\..\bindlib_w32\Release"
-# SUBTRACT LINK32 /pdb:none
-
-!ELSEIF "$(CFG)" == "dom - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "mssql-70" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "COMPILE_DL_DOM" /D ZTS=1 /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "DOM_EXPORTS" /D "COMPILE_DL_DOM" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_DOM=1 /D LIBXML_THREAD_ENABLED=1 /FR /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib /nologo /dll /machine:I386
-# ADD LINK32 php5ts_debug.lib ws2_32.lib resolv.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /incremental:yes /debug /machine:I386 /nodefaultlib:"msvcrt" /out:"..\..\Debug_TS\php_dom.dll" /implib:"..\..\Debug_TS/php_dom.lib" /libpath:"..\..\Debug_TS" /libpath:"..\..\..\bindlib_w32\Release"
-
-!ENDIF
-
-# Begin Target
-
-# Name "dom - Win32 Release_TS"
-# Name "dom - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\attr.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\cdatasection.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\characterdata.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\comment.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\document.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\documentfragment.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\documenttype.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\domconfiguration.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\domerror.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\domerrorhandler.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\domexception.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\domimplementation.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\domimplementationlist.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\domimplementationsource.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\domlocator.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\domstringlist.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\element.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\entity.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\entityreference.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\namednodemap.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\namelist.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\node.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\nodelist.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\notation.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_dom.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\processinginstruction.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\string_extend.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\text.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\typeinfo.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\userdatahandler.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\xpath.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\dom_ce.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\dom_fe.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\dom_properties.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_dom.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\xml_common.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# End Target
-# End Project
diff --git a/ext/dom/dom_ce.h b/ext/dom/dom_ce.h
index 0e1002536e..8e6a64ac85 100644
--- a/ext/dom/dom_ce.h
+++ b/ext/dom/dom_ce.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/dom_fe.h b/ext/dom/dom_fe.h
index b05c4aee42..67cf0d199d 100644
--- a/ext/dom/dom_fe.h
+++ b/ext/dom/dom_fe.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/dom_iterators.c b/ext/dom/dom_iterators.c
index 8b611b153d..ee892f3703 100644
--- a/ext/dom/dom_iterators.c
+++ b/ext/dom/dom_iterators.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/dom_properties.h b/ext/dom/dom_properties.h
index 60551bdca1..7e607f0a2e 100644
--- a/ext/dom/dom_properties.h
+++ b/ext/dom/dom_properties.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/domconfiguration.c b/ext/dom/domconfiguration.c
index 272fda8f8f..4c189606dc 100644
--- a/ext/dom/domconfiguration.c
+++ b/ext/dom/domconfiguration.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/domerror.c b/ext/dom/domerror.c
index cd35b326b7..2214c3f786 100644
--- a/ext/dom/domerror.c
+++ b/ext/dom/domerror.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/domerrorhandler.c b/ext/dom/domerrorhandler.c
index 78b75fe615..af73819ee1 100644
--- a/ext/dom/domerrorhandler.c
+++ b/ext/dom/domerrorhandler.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/domexception.c b/ext/dom/domexception.c
index b41b83c6cd..4696e87f21 100644
--- a/ext/dom/domexception.c
+++ b/ext/dom/domexception.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/domimplementation.c b/ext/dom/domimplementation.c
index c9394afc39..ea2b784b3c 100644
--- a/ext/dom/domimplementation.c
+++ b/ext/dom/domimplementation.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/domimplementationlist.c b/ext/dom/domimplementationlist.c
index 07479f52eb..b4d20172f0 100644
--- a/ext/dom/domimplementationlist.c
+++ b/ext/dom/domimplementationlist.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/domimplementationsource.c b/ext/dom/domimplementationsource.c
index 2e8a8d81b2..f3becc6454 100644
--- a/ext/dom/domimplementationsource.c
+++ b/ext/dom/domimplementationsource.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/domlocator.c b/ext/dom/domlocator.c
index 4e01b3a443..8fdd326fcc 100644
--- a/ext/dom/domlocator.c
+++ b/ext/dom/domlocator.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/domstringlist.c b/ext/dom/domstringlist.c
index a12d8633ac..6e8bc05bac 100644
--- a/ext/dom/domstringlist.c
+++ b/ext/dom/domstringlist.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/element.c b/ext/dom/element.c
index 03895280c4..0aff19561a 100644
--- a/ext/dom/element.c
+++ b/ext/dom/element.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/entity.c b/ext/dom/entity.c
index 1e229c4bd9..e0625fdd72 100644
--- a/ext/dom/entity.c
+++ b/ext/dom/entity.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/entityreference.c b/ext/dom/entityreference.c
index 4e020db124..1c3e60e4f1 100644
--- a/ext/dom/entityreference.c
+++ b/ext/dom/entityreference.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/namednodemap.c b/ext/dom/namednodemap.c
index 3d5dbe499e..ab314851be 100644
--- a/ext/dom/namednodemap.c
+++ b/ext/dom/namednodemap.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/namelist.c b/ext/dom/namelist.c
index 02b63af9ff..3f0b8e1640 100644
--- a/ext/dom/namelist.c
+++ b/ext/dom/namelist.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/node.c b/ext/dom/node.c
index 5868783565..b2079ffda2 100644
--- a/ext/dom/node.c
+++ b/ext/dom/node.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/nodelist.c b/ext/dom/nodelist.c
index a049491aee..68292d1983 100644
--- a/ext/dom/nodelist.c
+++ b/ext/dom/nodelist.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/notation.c b/ext/dom/notation.c
index dc63f1516d..b26608adcf 100644
--- a/ext/dom/notation.c
+++ b/ext/dom/notation.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/php_dom.c b/ext/dom/php_dom.c
index 7f1c19bd0e..8a00ad5a08 100644
--- a/ext/dom/php_dom.c
+++ b/ext/dom/php_dom.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/php_dom.h b/ext/dom/php_dom.h
index 628a19e978..9162031a90 100644
--- a/ext/dom/php_dom.h
+++ b/ext/dom/php_dom.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/processinginstruction.c b/ext/dom/processinginstruction.c
index a2bb1bd09f..a42cc9508b 100644
--- a/ext/dom/processinginstruction.c
+++ b/ext/dom/processinginstruction.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/string_extend.c b/ext/dom/string_extend.c
index 3d65a84bad..75680089a4 100644
--- a/ext/dom/string_extend.c
+++ b/ext/dom/string_extend.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/text.c b/ext/dom/text.c
index bb7ee2e99c..1cefa665aa 100644
--- a/ext/dom/text.c
+++ b/ext/dom/text.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/typeinfo.c b/ext/dom/typeinfo.c
index 5a437dc332..5267ee6f77 100644
--- a/ext/dom/typeinfo.c
+++ b/ext/dom/typeinfo.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/userdatahandler.c b/ext/dom/userdatahandler.c
index 6bddff6e73..e0b8756aa8 100644
--- a/ext/dom/userdatahandler.c
+++ b/ext/dom/userdatahandler.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/xml_common.h b/ext/dom/xml_common.h
index ed3d79b8a8..9d5ffe8fb6 100644
--- a/ext/dom/xml_common.h
+++ b/ext/dom/xml_common.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/dom/xpath.c b/ext/dom/xpath.c
index 107994f972..336365e342 100644
--- a/ext/dom/xpath.c
+++ b/ext/dom/xpath.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/enchant/enchant.c b/ext/enchant/enchant.c
index ba91f9b44c..ca33700982 100644
--- a/ext/enchant/enchant.c
+++ b/ext/enchant/enchant.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/ereg/ereg.c b/ext/ereg/ereg.c
index c1d92ba4e7..c626fef5c7 100644
--- a/ext/ereg/ereg.c
+++ b/ext/ereg/ereg.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/ereg/php_ereg.h b/ext/ereg/php_ereg.h
index d34d19855f..f1c2676772 100644
--- a/ext/ereg/php_ereg.h
+++ b/ext/ereg/php_ereg.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/ereg/php_regex.h b/ext/ereg/php_regex.h
index bb83b89fc9..3fd5a663a1 100644
--- a/ext/ereg/php_regex.h
+++ b/ext/ereg/php_regex.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/ereg/regex/regex.dsp b/ext/ereg/regex/regex.dsp
deleted file mode 100644
index e8f1ad4299..0000000000
--- a/ext/ereg/regex/regex.dsp
+++ /dev/null
@@ -1,106 +0,0 @@
-# Microsoft Developer Studio Project File - Name="regex" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 5.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=regex - Win32 Debug
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "regex.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "regex.mak" CFG="regex - Win32 Debug"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "regex - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "regex - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "regex - Win32 Release"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release"
-# PROP BASE Intermediate_Dir "Release"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release"
-# PROP Intermediate_Dir "Release"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /YX /FD /c
-# ADD CPP /nologo /MT /W3 /GX /O2 /I "." /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /o NUL /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /o NUL /win32
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /dll /machine:I386
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /dll /machine:I386
-
-!ELSEIF "$(CFG)" == "regex - Win32 Debug"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug"
-# PROP BASE Intermediate_Dir "Debug"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug"
-# PROP Intermediate_Dir "Debug"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /YX /FD /c
-# ADD CPP /nologo /MTd /W3 /Gm /GX /Zi /Od /I "." /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /YX /FD /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /o NUL /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /o NUL /win32
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:windows /dll /debug /machine:I386 /pdbtype:sept
-
-!ENDIF
-
-# Begin Target
-
-# Name "regex - Win32 Release"
-# Name "regex - Win32 Debug"
-# Begin Source File
-
-SOURCE=.\regcomp.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\regerror.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\regexec.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\regfree.c
-# End Source File
-# End Target
-# End Project
diff --git a/ext/ereg/regex/regex.dsw b/ext/ereg/regex/regex.dsw
deleted file mode 100644
index 7b7df8126c..0000000000
--- a/ext/ereg/regex/regex.dsw
+++ /dev/null
@@ -1,29 +0,0 @@
-Microsoft Developer Studio Workspace File, Format Version 5.00
-# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!
-
-###############################################################################
-
-Project: "regex"=.\regex.dsp - Package Owner=<4>
-
-Package=<5>
-{{{
-}}}
-
-Package=<4>
-{{{
-}}}
-
-###############################################################################
-
-Global:
-
-Package=<5>
-{{{
-}}}
-
-Package=<3>
-{{{
-}}}
-
-###############################################################################
-
diff --git a/ext/exif/exif.c b/ext/exif/exif.c
index fe60a3d8d4..42f8a24102 100644
--- a/ext/exif/exif.c
+++ b/ext/exif/exif.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/exif/exif.dsp b/ext/exif/exif.dsp
deleted file mode 100644
index 4a827338b2..0000000000
--- a/ext/exif/exif.dsp
+++ /dev/null
@@ -1,113 +0,0 @@
-# Microsoft Developer Studio Project File - Name="exif" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=exif - Win32 Release_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "exif.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "exif.mak" CFG="exif - Win32 Release_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "exif - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "exif - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "exif - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\TSRM" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "COMPILE_DL_EXIF" /D ZTS=1 /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /D ZEND_DEBUG=0 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "EXIF_EXPORTS" /D "COMPILE_DL_EXIF" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_EXIF=1 /FR /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib /nologo /dll /machine:I386
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_exif.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-
-!ELSEIF "$(CFG)" == "exif - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "COMPILE_DL_EXIF" /D ZTS=1 /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "EXIF_EXPORTS" /D "COMPILE_DL_EXIF" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_EXIF=1 /D "LIBZEND_EXPORTS" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib /nologo /dll /machine:I386
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts_debug.lib /nologo /dll /machine:I386 /out:"..\..\Debug_TS/php_exif.dll" /libpath:"..\..\Debug_TS"
-
-!ENDIF
-
-# Begin Target
-
-# Name "exif - Win32 Release_TS"
-# Name "exif - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\exif.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_exif.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# End Target
-# End Project
diff --git a/ext/exif/php_exif.h b/ext/exif/php_exif.h
index e0326752e6..8c2c207fa9 100644
--- a/ext/exif/php_exif.h
+++ b/ext/exif/php_exif.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/ext_skel b/ext/ext_skel
index e6b01fd4fc..c0c398d15e 100755
--- a/ext/ext_skel
+++ b/ext/ext_skel
@@ -156,12 +156,12 @@ if test "\$PHP_$EXTNAME" != "no"; then
dnl PHP_CHECK_LIBRARY(\$LIBNAME,\$LIBSYMBOL,
dnl [
- dnl PHP_ADD_LIBRARY_WITH_PATH(\$LIBNAME, \$${EXTNAME}_DIR/lib, ${EXTNAME}_SHARED_LIBADD)
+ dnl PHP_ADD_LIBRARY_WITH_PATH(\$LIBNAME, \$${EXTNAME}_DIR/\$PHP_LIBDIR, ${EXTNAME}_SHARED_LIBADD)
dnl AC_DEFINE(HAVE_${EXTNAME}LIB,1,[ ])
dnl ],[
dnl AC_MSG_ERROR([wrong $extname lib version or lib not found])
dnl ],[
- dnl -L\$${EXTNAME}_DIR/lib -lm
+ dnl -L\$${EXTNAME}_DIR/\$PHP_LIBDIR -lm
dnl ])
dnl
dnl PHP_SUBST(${EXTNAME}_SHARED_LIBADD)
diff --git a/ext/ext_skel_win32.php b/ext/ext_skel_win32.php
index c04f037657..770c6f48bb 100644
--- a/ext/ext_skel_win32.php
+++ b/ext/ext_skel_win32.php
@@ -35,20 +35,6 @@ foreach($argv as $arg) {
}
}
-$fp = fopen("$skel/skeleton.dsp", "rb");
-if ($fp) {
- $dsp_file = fread($fp, filesize("$skel/skeleton.dsp"));
- fclose($fp);
-
- $dsp_file = str_replace("extname", $extname, $dsp_file);
- $dsp_file = str_replace("EXTNAME", strtoupper($extname), $dsp_file);
- $fp = fopen("$extname/$extname.dsp", "wb");
- if ($fp) {
- fwrite($fp, $dsp_file);
- fclose($fp);
- }
-}
-
$fp = fopen("$extname/$extname.php", "rb");
if ($fp) {
$php_file = fread($fp, filesize("$extname/$extname.php"));
@@ -62,4 +48,5 @@ if ($fp) {
}
}
-?> \ No newline at end of file
+?>
+
diff --git a/ext/fileinfo/fileinfo.c b/ext/fileinfo/fileinfo.c
index 17edd2d40c..f365b38573 100644
--- a/ext/fileinfo/fileinfo.c
+++ b/ext/fileinfo/fileinfo.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/fileinfo/libmagic/apprentice.c b/ext/fileinfo/libmagic/apprentice.c
index 41a3ac5239..c1dc5aa1fa 100644
--- a/ext/fileinfo/libmagic/apprentice.c
+++ b/ext/fileinfo/libmagic/apprentice.c
@@ -1272,7 +1272,7 @@ file_signextend(struct magic_set *ms, struct magic *m, uint64_t v)
* the sign extension must have happened.
*/
case FILE_BYTE:
- v = (char) v;
+ v = (signed char) v;
break;
case FILE_SHORT:
case FILE_BESHORT:
diff --git a/ext/fileinfo/libmagic/softmagic.c b/ext/fileinfo/libmagic/softmagic.c
index 5fcc3a3c84..e626929c9e 100644
--- a/ext/fileinfo/libmagic/softmagic.c
+++ b/ext/fileinfo/libmagic/softmagic.c
@@ -1913,7 +1913,7 @@ convert_libmagic_pattern(zval *pattern, char *val, int len, int options)
t->val[j]='\0';
t->len = j;
- ZVAL_STR(pattern, t);
+ ZVAL_NEW_STR(pattern, t);
}
private int
diff --git a/ext/fileinfo/php_fileinfo.h b/ext/fileinfo/php_fileinfo.h
index 354ec7b284..d9c6c18c27 100644
--- a/ext/fileinfo/php_fileinfo.h
+++ b/ext/fileinfo/php_fileinfo.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/filter/callback_filter.c b/ext/filter/callback_filter.c
index 49410dbfe6..5a0ea0777d 100644
--- a/ext/filter/callback_filter.c
+++ b/ext/filter/callback_filter.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/filter/filter.c b/ext/filter/filter.c
index 873a6f83b3..7ef65bc196 100644
--- a/ext/filter/filter.c
+++ b/ext/filter/filter.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/filter/filter_private.h b/ext/filter/filter_private.h
index 4eec7b9119..8c41d8811e 100644
--- a/ext/filter/filter_private.h
+++ b/ext/filter/filter_private.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/filter/logical_filters.c b/ext/filter/logical_filters.c
index cbefae9d70..c37df628d2 100644
--- a/ext/filter/logical_filters.c
+++ b/ext/filter/logical_filters.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/filter/php_filter.h b/ext/filter/php_filter.h
index e62ef8c677..126a0c6c8b 100644
--- a/ext/filter/php_filter.h
+++ b/ext/filter/php_filter.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/filter/sanitizing_filters.c b/ext/filter/sanitizing_filters.c
index ca3059cd26..083b5382b6 100644
--- a/ext/filter/sanitizing_filters.c
+++ b/ext/filter/sanitizing_filters.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -20,7 +20,7 @@
#include "php_filter.h"
#include "filter_private.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
/* {{{ STRUCTS */
typedef unsigned long filter_map[256];
@@ -52,7 +52,7 @@ static void php_filter_encode_html(zval *value, const unsigned char *chars)
smart_str_0(&str);
zval_ptr_dtor(value);
- ZVAL_STR(value, str.s);
+ ZVAL_NEW_STR(value, str.s);
}
static const unsigned char hexchars[] = "0123456789ABCDEF";
@@ -105,7 +105,7 @@ static void php_filter_encode_url(zval *value, const unsigned char* chars, const
*p = '\0';
str->len = p - (unsigned char *)str->val;
zval_ptr_dtor(value);
- ZVAL_STR(value, str);
+ ZVAL_NEW_STR(value, str);
}
static void php_filter_strip(zval *value, zend_long flags)
@@ -135,7 +135,7 @@ static void php_filter_strip(zval *value, zend_long flags)
buf->val[c] = '\0';
buf->len = c;
zval_ptr_dtor(value);
- ZVAL_STR(value, buf);
+ ZVAL_NEW_STR(value, buf);
}
/* }}} */
@@ -174,7 +174,7 @@ static void filter_map_apply(zval *value, filter_map *map)
buf->val[c] = '\0';
buf->len = c;
zval_ptr_dtor(value);
- ZVAL_STR(value, buf);
+ ZVAL_NEW_STR(value, buf);
}
/* }}} */
@@ -184,7 +184,7 @@ void php_filter_string(PHP_INPUT_FILTER_PARAM_DECL)
size_t new_len;
unsigned char enc[256] = {0};
- if (IS_INTERNED(Z_STR_P(value))) {
+ if (!Z_REFCOUNTED_P(value)) {
ZVAL_STRINGL(value, Z_STRVAL_P(value), Z_STRLEN_P(value));
}
diff --git a/ext/ftp/ftp.c b/ext/ftp/ftp.c
index 27051677c9..a5341080b8 100644
--- a/ext/ftp/ftp.c
+++ b/ext/ftp/ftp.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/ftp/ftp.h b/ext/ftp/ftp.h
index 57b3f663d7..f2051fe195 100644
--- a/ext/ftp/ftp.h
+++ b/ext/ftp/ftp.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/ftp/php_ftp.c b/ext/ftp/php_ftp.c
index 1a1961122e..32d8fb86e2 100644
--- a/ext/ftp/php_ftp.c
+++ b/ext/ftp/php_ftp.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/ftp/php_ftp.h b/ext/ftp/php_ftp.h
index fffe6bf2f5..bd8de97483 100644
--- a/ext/ftp/php_ftp.h
+++ b/ext/ftp/php_ftp.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/gd/gd.c b/ext/gd/gd.c
index 97e625742f..ade37aa575 100644
--- a/ext/gd/gd.c
+++ b/ext/gd/gd.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/gd/gd.dsp b/ext/gd/gd.dsp
deleted file mode 100644
index d7207562f8..0000000000
--- a/ext/gd/gd.dsp
+++ /dev/null
@@ -1,600 +0,0 @@
-# Microsoft Developer Studio Project File - Name="gd" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=gd - Win32 Release_TS GD2
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "gd.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "gd.mak" CFG="gd - Win32 Release_TS GD2"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "gd - Win32 Release_TS GD2" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "gd - Win32 Debug_TS GD2" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "gd___Win32_Release_TS_GD2_bundled"
-# PROP BASE Intermediate_Dir "gd___Win32_Release_TS_GD2_bundled"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\zlib" /I "..\..\TSRM" /D ZEND_DEBUG=0 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "COMPILE_DL_GD" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_GD_GIF_READ=1 /D HAVE_GD_GIF_CREATE=1 /D HAVE_GDIMAGECOLORRESOLVE=1 /D "HAVE_GD_PNG" /D "HAVE_GD_JPG" /D "HAVE_GD_WBMP" /D "HAVE_GD_XBM" /D HAVE_LIBGD13=1 /D HAVE_LIBGD=1 /D HAVE_LIBGD15=1 /D HAVE_LIBGD204=1 /FR /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\zlib" /I "..\..\TSRM" /I "libgd" /D ZEND_DEBUG=0 /D HAVE_LIBGD15=1 /D HAVE_LIBGD204=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "COMPILE_DL_GD" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_GD_GIF_READ=1 /D HAVE_GD_GIF_CREATE=1 /D HAVE_GDIMAGECOLORRESOLVE=1 /D "HAVE_GD_PNG" /D "HAVE_GD_JPG" /D "HAVE_GD_WBMP" /D "HAVE_GD_XBM" /D HAVE_LIBGD=1 /D HAVE_LIBGD13=1 /D HAVE_LIBGD20=1 /D "USE_GD_IOCTX" /D HAVE_LIBFREETYPE=1 /D "USE_GD_IMGSTRTTF" /D HAVE_GD_STRINGTTF=1 /D HAVE_GD_BUNDLED=1 /D "MSWIN32" /D "HAVE_LIBPNG" /D "HAVE_LIBJPEG" /D "HAVE_GD_GD2" /D HAVE_GD_STRINGFTEX=1 /D HAVE_GD_IMAGESETBRUSH=1 /D HAVE_GD_IMAGESETTILE=1 /FR /FD /c
-# SUBTRACT CPP /YX
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 php5ts.lib libjpeg.lib libpng.lib zlib.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_gd2.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-# SUBTRACT BASE LINK32 /pdb:none
-# ADD LINK32 php5ts.lib freetype2.lib libjpeg.lib libpng.lib zlib.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_gd2.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline" /libpath:"..\..\..\zlib\Release"
-# SUBTRACT LINK32 /pdb:none
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "gd___Win32_Debug_TS_GD2_bundled"
-# PROP BASE Intermediate_Dir "gd___Win32_Debug_TS_GD2_bundled"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MDd /W3 /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\zlib" /I "..\..\TSRM" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "COMPILE_DL_GD" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_GD_GIF_READ=1 /D HAVE_GD_GIF_CREATE=1 /D HAVE_GDIMAGECOLORRESOLVE=1 /D "HAVE_GD_PNG" /D "HAVE_GD_JPG" /D "HAVE_GD_WBMP" /D HAVE_LIBGD13=1 /D HAVE_LIBGD=1 /D HAVE_LIBGD15=1 /D HAVE_LIBGD204=1 /FR /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\zlib" /I "..\..\TSRM" /I "libgd" /D ZEND_DEBUG=1 /D "HAVE_LIBGD15" /D HAVE_LIBGD204=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "COMPILE_DL_GD" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_GD_GIF_READ=1 /D HAVE_GD_GIF_CREATE=1 /D HAVE_GDIMAGECOLORRESOLVE=1 /D "HAVE_GD_PNG" /D "HAVE_GD_JPG" /D "HAVE_GD_WBMP" /D HAVE_LIBGD=1 /D HAVE_LIBGD13=1 /D HAVE_LIBGD20=1 /D "USE_GD_IOCTX" /D HAVE_LIBFREETYPE=1 /D "USE_GD_IMGSTRTTF" /D HAVE_GD_STRINGTTF=1 /D HAVE_GD_BUNDLED=1 /D "MSWIN32" /D "HAVE_LIBPNG" /D "HAVE_LIBJPEG" /D "HAVE_GD_GD2" /D HAVE_GD_STRINGFTEX=1 /D HAVE_GD_IMAGESETBRUSH=1 /D HAVE_GD_IMAGESETTILE=1 /FR /FD /c
-# SUBTRACT CPP /YX
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 php5ts_debug.lib libjpeg.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /incremental:yes /debug /machine:I386 /out:"..\..\Debug_TS/php_gd2.dll" /libpath:"..\..\Debug_TS"
-# SUBTRACT BASE LINK32 /pdb:none
-# ADD LINK32 php5ts_debug.lib libpng.lib zlib.lib libjpeg.lib freetype2.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /incremental:yes /debug /machine:I386 /out:"..\..\Debug_TS/php_gd2.dll" /libpath:"..\..\Debug_TS" /libpath:"..\..\..\zlib\Debug"
-# SUBTRACT LINK32 /pdb:none
-
-!ENDIF
-
-# Begin Target
-
-# Name "gd - Win32 Release_TS GD2"
-# Name "gd - Win32 Debug_TS GD2"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\gd.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\gdttf.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\gdcache.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\gdttf.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_gd.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# Begin Group "libgd"
-
-# PROP Default_Filter ""
-# Begin Group "Source Files No. 1"
-
-# PROP Default_Filter "*.c"
-# Begin Source File
-
-SOURCE=.\libgd\gd.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gd2copypal.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gd_arc_f_buggy.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gd_gd.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gd_gd2.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gd_gif_in.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gd_gif_out.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gd_io.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gd_io_dp.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gd_io_file.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gd_io_ss.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gd_jpeg.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gd_png.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gd_ss.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gd_topal.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gd_wbmp.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gdcache.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gdfontg.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gdfontl.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gdfontmb.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gdfonts.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gdfontt.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gdft.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gdhelpers.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gdkanji.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gdtables.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gdxpm.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\wbmp.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\xbm.c
-
-!IF "$(CFG)" == "gd - Win32 Release_TS GD2"
-
-# PROP Intermediate_Dir "Release_TS_bundled"
-
-!ELSEIF "$(CFG)" == "gd - Win32 Debug_TS GD2"
-
-# PROP Intermediate_Dir "Debug_TS_bundled"
-
-!ENDIF
-
-# End Source File
-# End Group
-# Begin Group "Header Files No. 1"
-
-# PROP Default_Filter "*.h"
-# Begin Source File
-
-SOURCE=.\libgd\gd.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gd_io.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gdcache.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gdfontg.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gdfontl.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gdfontmb.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gdfonts.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gdfontt.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\gdhelpers.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\jisx0208.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libgd\wbmp.h
-# End Source File
-# End Group
-# End Group
-# End Target
-# End Project
diff --git a/ext/gd/gd_ctx.c b/ext/gd/gd_ctx.c
index 5c378ffb0f..0b79cb6f0d 100644
--- a/ext/gd/gd_ctx.c
+++ b/ext/gd/gd_ctx.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/gd/libgd/xbm.c b/ext/gd/libgd/xbm.c
index d6fdd7d086..5a7d016ee8 100644
--- a/ext/gd/libgd/xbm.c
+++ b/ext/gd/libgd/xbm.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/gd/php_gd.h b/ext/gd/php_gd.h
index 1f32a8f9b1..7510b2425d 100644
--- a/ext/gd/php_gd.h
+++ b/ext/gd/php_gd.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/gd/tests/bug48801_1.phpt b/ext/gd/tests/bug48801_1.phpt
index ef2aa1dba7..0ab6d7cdd9 100644
--- a/ext/gd/tests/bug48801_1.phpt
+++ b/ext/gd/tests/bug48801_1.phpt
@@ -1,13 +1,12 @@
--TEST--
-Bug #48801 (Problem with imagettfbbox) freetype >= 2.4.10 and < 2.4.12
+Bug #48801 (Problem with imagettfbbox) freetype >= 2.4.10
--SKIPIF--
<?php
if(!extension_loaded('gd')){ die('skip gd extension not available'); }
if(!function_exists('imageftbbox')) die('skip imageftbbox() not available');
include dirname(__FILE__) . '/func.inc';
- if(version_compare(get_freetype_version(), '2.4.10') < 0) die('skip for freetype >= 2.4.10');
- if(version_compare(get_freetype_version(), '2.4.12') >= 0) die('skip for freetype < 2.4.12');
+ if(version_compare(get_freetype_version(), '2.4.10') == -1) die('skip for freetype >= 2.4.10');
?>
--FILE--
<?php
@@ -21,6 +20,6 @@ echo '(' . $bbox[6] . ', ' . $bbox[7] . ")\n";
?>
--EXPECTF--
(-1, 15)
-(156, 15)
-(156, -48)
+(15%d, 15)
+(15%d, -48)
(-1, -48)
diff --git a/ext/gd/tests/bug48801_2.phpt b/ext/gd/tests/bug48801_2.phpt
deleted file mode 100644
index b2a719fa02..0000000000
--- a/ext/gd/tests/bug48801_2.phpt
+++ /dev/null
@@ -1,25 +0,0 @@
---TEST--
-Bug #48801 (Problem with imagettfbbox) freetype >= 2.4.12
---SKIPIF--
-<?php
- if(!extension_loaded('gd')){ die('skip gd extension not available'); }
- if(!function_exists('imageftbbox')) die('skip imageftbbox() not available');
-
- include dirname(__FILE__) . '/func.inc';
- if(version_compare(get_freetype_version(), '2.4.12') < 0) die('skip for freetype >= 2.4.12');
-?>
---FILE--
-<?php
-$cwd = dirname(__FILE__);
-$font = "$cwd/Tuffy.ttf";
-$bbox = imageftbbox(50, 0, $font, "image");
-echo '(' . $bbox[0] . ', ' . $bbox[1] . ")\n";
-echo '(' . $bbox[2] . ', ' . $bbox[3] . ")\n";
-echo '(' . $bbox[4] . ', ' . $bbox[5] . ")\n";
-echo '(' . $bbox[6] . ', ' . $bbox[7] . ")\n";
-?>
---EXPECTF--
-(-1, 15)
-(155, 15)
-(155, -48)
-(-1, -48)
diff --git a/ext/gettext/gettext.c b/ext/gettext/gettext.c
index 3f1909e753..938997a4a6 100644
--- a/ext/gettext/gettext.c
+++ b/ext/gettext/gettext.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/gettext/gettext.dsp b/ext/gettext/gettext.dsp
deleted file mode 100644
index 79ea194854..0000000000
--- a/ext/gettext/gettext.dsp
+++ /dev/null
@@ -1,113 +0,0 @@
-# Microsoft Developer Studio Project File - Name="gettext" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=gettext - Win32 Release_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "gettext.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "gettext.mak" CFG="gettext - Win32 Release_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "gettext - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "gettext - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "gettext - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\TSRM" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "COMPILE_DL_GETTEXT" /D ZTS=1 /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /D ZEND_DEBUG=0 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "GETTEXT_EXPORTS" /D "COMPILE_DL_GETTEXT" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_LIBINTL=1 /D HAVE_BIND_TEXTDOMAIN_CODESET=1 /D HAVE_NGETTEXT=1 /D HAVE_DNGETTEXT=1 /FR /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_gettext.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-# ADD LINK32 php5ts.lib libintl.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_gettext.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-
-!ELSEIF "$(CFG)" == "gettext - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MSSQL_EXPORTS" /D "COMPILE_DL_GETTEXT" /D ZTS=1 /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /D ZEND_DEBUG=1 /D HAVE_NGETTEXT=1 /D HAVE_DNGETTEXT=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "GETTEXT_EXPORTS" /D "COMPILE_DL_GETTEXT" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_LIBINTL=1 /D HAVE_BIND_TEXTDOMAIN_CODESET=1 /FR /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib /nologo /dll /machine:I386 /out:"../../Debug_TS/php_gettext.dll" /libpath:"..\..\Debug_TS"
-# ADD LINK32 php5ts_debug.lib libintl.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /incremental:yes /debug /machine:I386 /out:"../../Debug_TS/php_gettext.dll" /libpath:"..\..\Debug_TS"
-
-!ENDIF
-
-# Begin Target
-
-# Name "gettext - Win32 Release_TS"
-# Name "gettext - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\gettext.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_gettext.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# End Target
-# End Project
diff --git a/ext/gettext/php_gettext.h b/ext/gettext/php_gettext.h
index f990d32af5..ab4f5fc764 100644
--- a/ext/gettext/php_gettext.h
+++ b/ext/gettext/php_gettext.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/gmp/config.m4 b/ext/gmp/config.m4
index 2140aaf701..0388d548cf 100644
--- a/ext/gmp/config.m4
+++ b/ext/gmp/config.m4
@@ -1,7 +1,3 @@
-dnl
-dnl $Id$
-dnl
-
PHP_ARG_WITH(gmp, for GNU MP support,
[ --with-gmp[=DIR] Include GNU MP support])
@@ -15,14 +11,9 @@ if test "$PHP_GMP" != "no"; then
AC_MSG_ERROR(Unable to locate gmp.h)
fi
- PHP_CHECK_LIBRARY(gmp, __gmp_randinit_lc_2exp_size,
+ PHP_CHECK_LIBRARY(gmp, __gmpz_rootrem,
[],[
- PHP_CHECK_LIBRARY(gmp, gmp_randinit_lc_2exp_size,
- [],[
- AC_MSG_ERROR([GNU MP Library version 4.1.2 or greater required.])
- ],[
- -L$GMP_DIR/$PHP_LIBDIR
- ])
+ AC_MSG_ERROR([GNU MP Library version 4.2 or greater required.])
],[
-L$GMP_DIR/$PHP_LIBDIR
])
diff --git a/ext/gmp/gmp.c b/ext/gmp/gmp.c
index 7eb9eef494..b5c18ecb37 100644
--- a/ext/gmp/gmp.c
+++ b/ext/gmp/gmp.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -25,7 +25,7 @@
#include "php_gmp.h"
#include "ext/standard/info.h"
#include "ext/standard/php_var.h"
-#include "ext/standard/php_smart_str_public.h"
+#include "zend_smart_str_public.h"
#include "zend_exceptions.h"
#if HAVE_GMP
@@ -224,16 +224,7 @@ typedef struct _gmp_temp {
#define GMP_BIG_ENDIAN (1 << 3)
#define GMP_NATIVE_ENDIAN (1 << 4)
-#define GMP_42_OR_NEWER \
- ((__GNU_MP_VERSION >= 5) || (__GNU_MP_VERSION >= 4 && __GNU_MP_VERSION_MINOR >= 2))
-
-/* The maximum base for input and output conversions is 62 from GMP 4.2
- * onwards. */
-#if GMP_42_OR_NEWER
-# define MAX_BASE 62
-#else
-# define MAX_BASE 36
-#endif
+#define GMP_MAX_BASE 62
#define IS_GMP(zval) \
(Z_TYPE_P(zval) == IS_OBJECT && instanceof_function(Z_OBJCE_P(zval), gmp_ce TSRMLS_CC))
@@ -569,7 +560,7 @@ static int gmp_compare(zval *result, zval *op1, zval *op2 TSRMLS_DC) /* {{{ */
}
/* }}} */
-static int gmp_serialize(zval *object, unsigned char **buffer, uint32_t *buf_len, zend_serialize_data *data TSRMLS_DC) /* {{{ */
+static int gmp_serialize(zval *object, unsigned char **buffer, size_t *buf_len, zend_serialize_data *data TSRMLS_DC) /* {{{ */
{
mpz_ptr gmpnum = GET_GMP_FROM_ZVAL(object);
smart_str buf = {0};
@@ -596,7 +587,7 @@ static int gmp_serialize(zval *object, unsigned char **buffer, uint32_t *buf_len
}
/* }}} */
-static int gmp_unserialize(zval *object, zend_class_entry *ce, const unsigned char *buf, uint32_t buf_len, zend_unserialize_data *data TSRMLS_DC) /* {{{ */
+static int gmp_unserialize(zval *object, zend_class_entry *ce, const unsigned char *buf, size_t buf_len, zend_unserialize_data *data TSRMLS_DC) /* {{{ */
{
mpz_ptr gmpnum;
const unsigned char *p, *max;
@@ -790,7 +781,7 @@ static void gmp_strval(zval *result, mpz_t gmpnum, zend_long base) /* {{{ */
str->val[str->len] = '\0';
}
- ZVAL_STR(result, str);
+ ZVAL_NEW_STR(result, str);
}
/* }}} */
@@ -1048,8 +1039,8 @@ ZEND_FUNCTION(gmp_init)
return;
}
- if (base && (base < 2 || base > MAX_BASE)) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Bad base for conversion: %pd (should be between 2 and %d)", base, MAX_BASE);
+ if (base && (base < 2 || base > GMP_MAX_BASE)) {
+ php_error_docref(NULL TSRMLS_CC, E_WARNING, "Bad base for conversion: %pd (should be between 2 and %d)", base, GMP_MAX_BASE);
RETURN_FALSE;
}
@@ -1204,15 +1195,10 @@ ZEND_FUNCTION(gmp_strval)
return;
}
-#if MAX_BASE == 62
- /* Although the maximum base in general in GMP >= 4.2 is 62, mpz_get_str()
+ /* Although the maximum base in general in GMP is 62, mpz_get_str()
* is explicitly limited to -36 when dealing with negative bases. */
- if ((base < 2 && base > -2) || base > MAX_BASE || base < -36) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Bad base for conversion: %pd (should be between 2 and %d or -2 and -36)", base, MAX_BASE);
-#else
- if (base < 2 || base > MAX_BASE) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Bad base for conversion: %pd (should be between 2 and %d)", base, MAX_BASE);
-#endif
+ if ((base < 2 && base > -2) || base > GMP_MAX_BASE || base < -36) {
+ php_error_docref(NULL TSRMLS_CC, E_WARNING, "Bad base for conversion: %pd (should be between 2 and %d or -2 and -36)", base, GMP_MAX_BASE);
RETURN_FALSE;
}
@@ -1596,14 +1582,7 @@ ZEND_FUNCTION(gmp_rootrem)
add_next_index_zval(return_value, &result1);
add_next_index_zval(return_value, &result2);
-#if GMP_42_OR_NEWER
mpz_rootrem(gmpnum_result1, gmpnum_result2, gmpnum_a, (gmp_ulong) nth);
-#else
- mpz_root(gmpnum_result1, gmpnum_a, (gmp_ulong) nth);
- mpz_pow_ui(gmpnum_result2, gmpnum_result1, (gmp_ulong) nth);
- mpz_sub(gmpnum_result2, gmpnum_a, gmpnum_result2);
- mpz_abs(gmpnum_result2, gmpnum_result2);
-#endif
FREE_GMP_TEMP(temp_a);
}
@@ -1779,7 +1758,7 @@ ZEND_FUNCTION(gmp_random)
if (!GMPG(rand_initialized)) {
/* Initialize */
- gmp_randinit_lc_2exp_size(GMPG(rand_state), 32L);
+ gmp_randinit_mt(GMPG(rand_state));
/* Seed */
gmp_randseed_ui(GMPG(rand_state), GENERATE_SEED());
@@ -1849,7 +1828,7 @@ ZEND_FUNCTION(gmp_setbit)
if (index < 0) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Index must be greater than or equal to zero");
- return;
+ RETURN_FALSE;
}
gmpnum_a = GET_GMP_FROM_ZVAL(a_arg);
@@ -1876,7 +1855,7 @@ ZEND_FUNCTION(gmp_clrbit)
if (index < 0) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Index must be greater than or equal to zero");
- return;
+ RETURN_FALSE;
}
gmpnum_a = GET_GMP_FROM_ZVAL(a_arg);
diff --git a/ext/gmp/php_gmp.h b/ext/gmp/php_gmp.h
index bce2a9eaca..59485dd5b7 100644
--- a/ext/gmp/php_gmp.h
+++ b/ext/gmp/php_gmp.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/gmp/tests/bug50283.phpt b/ext/gmp/tests/bug50283.phpt
index 13eef54804..561cd3d68c 100644
--- a/ext/gmp/tests/bug50283.phpt
+++ b/ext/gmp/tests/bug50283.phpt
@@ -2,7 +2,6 @@
Feature Request #50283 (allow base in gmp_strval to use full range: 2 to 62, and -2 to -36)
--SKIPIF--
<?php if (!extension_loaded("gmp")) print "skip"; ?>
-<?php if (version_compare(GMP_VERSION, "4.2.0", "<")) print "skip"; ?>
--FILE--
<?php
$a = gmp_init("0x41682179fbf5");
diff --git a/ext/gmp/tests/gmp_clrbit.phpt b/ext/gmp/tests/gmp_clrbit.phpt
index 079d5d669f..0aab89dd37 100644
--- a/ext/gmp/tests/gmp_clrbit.phpt
+++ b/ext/gmp/tests/gmp_clrbit.phpt
@@ -10,7 +10,7 @@ gmp_clrbit($n, 0);
var_dump(gmp_strval($n));
$n = gmp_init(-1);
-gmp_clrbit($n, -1);
+var_dump(gmp_clrbit($n, -1));
var_dump(gmp_strval($n));
$n = gmp_init("1000000");
@@ -35,10 +35,11 @@ gmp_clrbit();
echo "Done\n";
?>
---EXPECTF--
+--EXPECTF--
string(1) "0"
Warning: gmp_clrbit(): Index must be greater than or equal to zero in %s on line %d
+bool(false)
string(2) "-1"
Warning: gmp_clrbit(): Index must be greater than or equal to zero in %s on line %d
diff --git a/ext/gmp/tests/gmp_setbit.phpt b/ext/gmp/tests/gmp_setbit.phpt
index 99848959d5..2eac23db0e 100644
--- a/ext/gmp/tests/gmp_setbit.phpt
+++ b/ext/gmp/tests/gmp_setbit.phpt
@@ -10,7 +10,7 @@ gmp_setbit($n, 10, -1);
var_dump(gmp_strval($n));
$n = gmp_init(5);
-gmp_setbit($n, -20, 0);
+var_dump(gmp_setbit($n, -20, 0));
var_dump(gmp_strval($n));
$n = gmp_init(5);
@@ -41,10 +41,11 @@ gmp_setbit($a,array());
echo "Done\n";
?>
---EXPECTF--
+--EXPECTF--
string(2) "-1"
Warning: gmp_setbit(): Index must be greater than or equal to zero in %s on line %d
+bool(false)
string(1) "5"
string(1) "1"
string(1) "7"
diff --git a/ext/hash/hash.c b/ext/hash/hash.c
index 5a4529d0f5..406f074da3 100644
--- a/ext/hash/hash.c
+++ b/ext/hash/hash.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -287,7 +287,7 @@ static void php_hash_do_hash_hmac(INTERNAL_FUNCTION_PARAMETERS, int isfilename,
php_hash_hmac_round((unsigned char *) digest->val, ops, context, K, (unsigned char *) digest->val, ops->digest_size);
/* Zero the key */
- memset(K, 0, ops->block_size);
+ ZEND_SECURE_ZERO(K, ops->block_size);
efree(K);
efree(context);
@@ -515,7 +515,7 @@ PHP_FUNCTION(hash_final)
hash->ops->hash_final((unsigned char *) digest->val, hash->context);
/* Zero the key */
- memset(hash->key, 0, hash->ops->block_size);
+ ZEND_SECURE_ZERO(hash->key, hash->ops->block_size);
efree(hash->key);
hash->key = NULL;
}
@@ -698,9 +698,9 @@ PHP_FUNCTION(hash_pbkdf2)
memcpy(result + ((i - 1) * ops->digest_size), temp, ops->digest_size);
}
/* Zero potentially sensitive variables */
- memset(K1, 0, ops->block_size);
- memset(K2, 0, ops->block_size);
- memset(computed_salt, 0, salt_len + 4);
+ ZEND_SECURE_ZERO(K1, ops->block_size);
+ ZEND_SECURE_ZERO(K2, ops->block_size);
+ ZEND_SECURE_ZERO(computed_salt, salt_len + 4);
efree(K1);
efree(K2);
efree(computed_salt);
@@ -975,7 +975,7 @@ PHP_FUNCTION(mhash_keygen_s2k)
}
RETVAL_STRINGL(key, bytes);
- memset(key, 0, bytes);
+ ZEND_SECURE_ZERO(key, bytes);
efree(digest);
efree(context);
efree(key);
diff --git a/ext/hash/hash_adler32.c b/ext/hash/hash_adler32.c
index af5ff82de0..22ab2f29ac 100644
--- a/ext/hash/hash_adler32.c
+++ b/ext/hash/hash_adler32.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/hash/hash_crc32.c b/ext/hash/hash_crc32.c
index 7e748df559..7e9a78e4a6 100644
--- a/ext/hash/hash_crc32.c
+++ b/ext/hash/hash_crc32.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/hash/hash_fnv.c b/ext/hash/hash_fnv.c
index 1c92478259..8433678ba9 100644
--- a/ext/hash/hash_fnv.c
+++ b/ext/hash/hash_fnv.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/hash/hash_gost.c b/ext/hash/hash_gost.c
index bda9579830..9fb8f2a5fb 100644
--- a/ext/hash/hash_gost.c
+++ b/ext/hash/hash_gost.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -281,7 +281,7 @@ PHP_HASH_API void PHP_GOSTUpdate(PHP_GOST_CTX *context, const unsigned char *inp
}
memcpy(context->buffer, input + i, r);
- memset(&context->buffer[r], 0, 32 - r);
+ ZEND_SECURE_ZERO(&context->buffer[r], 32 - r);
context->length = r;
}
}
@@ -306,7 +306,7 @@ PHP_HASH_API void PHP_GOSTFinal(unsigned char digest[32], PHP_GOST_CTX *context)
digest[j + 3] = (unsigned char) ((context->state[i] >> 24) & 0xff);
}
- memset(context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO(context, sizeof(*context));
}
const php_hash_ops php_hash_gost_ops = {
diff --git a/ext/hash/hash_haval.c b/ext/hash/hash_haval.c
index 32437cecdf..bc62954e6f 100644
--- a/ext/hash/hash_haval.c
+++ b/ext/hash/hash_haval.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -169,7 +169,7 @@ static void PHP_3HAVALTransform(php_hash_uint32 state[8], const unsigned char bl
}
/* Zeroize sensitive information. */
- memset((unsigned char*) x, 0, sizeof(x));
+ ZEND_SECURE_ZERO((unsigned char*) x, sizeof(x));
}
/* }}} */
@@ -206,7 +206,7 @@ static void PHP_4HAVALTransform(php_hash_uint32 state[8], const unsigned char bl
}
/* Zeroize sensitive information. */
- memset((unsigned char*) x, 0, sizeof(x));
+ ZEND_SECURE_ZERO((unsigned char*) x, sizeof(x));
}
/* }}} */
@@ -245,7 +245,7 @@ static void PHP_5HAVALTransform(php_hash_uint32 state[8], const unsigned char bl
}
/* Zeroize sensitive information. */
- memset((unsigned char*) x, 0, sizeof(x));
+ ZEND_SECURE_ZERO((unsigned char*) x, sizeof(x));
}
/* }}} */
@@ -368,7 +368,7 @@ PHP_HASH_API void PHP_HAVAL128Final(unsigned char *digest, PHP_HAVAL_CTX * conte
/* Zeroize sensitive information.
*/
- memset((unsigned char*) context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO((unsigned char*) context, sizeof(*context));
}
/* }}} */
@@ -422,7 +422,7 @@ PHP_HASH_API void PHP_HAVAL160Final(unsigned char *digest, PHP_HAVAL_CTX * conte
/* Zeroize sensitive information.
*/
- memset((unsigned char*) context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO((unsigned char*) context, sizeof(*context));
}
/* }}} */
@@ -462,7 +462,7 @@ PHP_HASH_API void PHP_HAVAL192Final(unsigned char *digest, PHP_HAVAL_CTX * conte
/* Zeroize sensitive information.
*/
- memset((unsigned char*) context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO((unsigned char*) context, sizeof(*context));
}
/* }}} */
@@ -503,7 +503,7 @@ PHP_HASH_API void PHP_HAVAL224Final(unsigned char *digest, PHP_HAVAL_CTX * conte
/* Zeroize sensitive information.
*/
- memset((unsigned char*) context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO((unsigned char*) context, sizeof(*context));
}
/* }}} */
@@ -537,7 +537,7 @@ PHP_HASH_API void PHP_HAVAL256Final(unsigned char *digest, PHP_HAVAL_CTX * conte
/* Zeroize sensitive information.
*/
- memset((unsigned char*) context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO((unsigned char*) context, sizeof(*context));
}
/* }}} */
diff --git a/ext/hash/hash_joaat.c b/ext/hash/hash_joaat.c
index cfeab863de..84f65b7609 100644
--- a/ext/hash/hash_joaat.c
+++ b/ext/hash/hash_joaat.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/hash/hash_md.c b/ext/hash/hash_md.c
index 92f97ee506..98891f3b77 100644
--- a/ext/hash/hash_md.c
+++ b/ext/hash/hash_md.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -344,7 +344,7 @@ PHP_HASH_API void PHP_MD5Final(unsigned char digest[16], PHP_MD5_CTX * context)
/* Zeroize sensitive information.
*/
- memset((unsigned char*) context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO((unsigned char*) context, sizeof(*context));
}
/* }}} */
@@ -437,7 +437,7 @@ const unsigned char block[64];
state[3] += d;
/* Zeroize sensitive information. */
- memset((unsigned char*) x, 0, sizeof(x));
+ ZEND_SECURE_ZERO((unsigned char*) x, sizeof(x));
}
/* }}} */
@@ -602,7 +602,7 @@ PHP_HASH_API void PHP_MD4Final(unsigned char digest[16], PHP_MD4_CTX * context)
/* Zeroize sensitive information.
*/
- memset((unsigned char*) context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO((unsigned char*) context, sizeof(*context));
}
/* }}} */
diff --git a/ext/hash/hash_ripemd.c b/ext/hash/hash_ripemd.c
index 16fbd12b18..740cb78220 100644
--- a/ext/hash/hash_ripemd.c
+++ b/ext/hash/hash_ripemd.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -244,7 +244,7 @@ static void RIPEMD128Transform(php_hash_uint32 state[4], const unsigned char blo
state[0] = tmp;
tmp = 0;
- memset(x, 0, sizeof(x));
+ ZEND_SECURE_ZERO(x, sizeof(x));
}
/* }}} */
@@ -342,7 +342,7 @@ static void RIPEMD256Transform(php_hash_uint32 state[8], const unsigned char blo
state[7] += dd;
tmp = 0;
- memset(x, 0, sizeof(x));
+ ZEND_SECURE_ZERO(x, sizeof(x));
}
/* }}} */
@@ -441,7 +441,7 @@ static void RIPEMD160Transform(php_hash_uint32 state[5], const unsigned char blo
state[0] = tmp;
tmp = 0;
- memset(x, 0, sizeof(x));
+ ZEND_SECURE_ZERO(x, sizeof(x));
}
/* }}} */
@@ -549,7 +549,7 @@ static void RIPEMD320Transform(php_hash_uint32 state[10], const unsigned char bl
state[9] += ee;
tmp = 0;
- memset(x, 0, sizeof(x));
+ ZEND_SECURE_ZERO(x, sizeof(x));
}
/* }}} */
@@ -650,7 +650,7 @@ PHP_HASH_API void PHP_RIPEMD128Final(unsigned char digest[16], PHP_RIPEMD128_CTX
/* Zeroize sensitive information.
*/
- memset((unsigned char*) context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO((unsigned char*) context, sizeof(*context));
}
/* }}} */
@@ -687,7 +687,7 @@ PHP_HASH_API void PHP_RIPEMD256Final(unsigned char digest[32], PHP_RIPEMD256_CTX
/* Zeroize sensitive information.
*/
- memset((unsigned char*) context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO((unsigned char*) context, sizeof(*context));
}
/* }}} */
@@ -724,7 +724,7 @@ PHP_HASH_API void PHP_RIPEMD160Final(unsigned char digest[20], PHP_RIPEMD160_CTX
/* Zeroize sensitive information.
*/
- memset((unsigned char*) context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO((unsigned char*) context, sizeof(*context));
}
/* }}} */
@@ -761,7 +761,7 @@ PHP_HASH_API void PHP_RIPEMD320Final(unsigned char digest[40], PHP_RIPEMD320_CTX
/* Zeroize sensitive information.
*/
- memset((unsigned char*) context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO((unsigned char*) context, sizeof(*context));
}
/* }}} */
diff --git a/ext/hash/hash_sha.c b/ext/hash/hash_sha.c
index d60a7a9780..003f05a774 100644
--- a/ext/hash/hash_sha.c
+++ b/ext/hash/hash_sha.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -321,7 +321,7 @@ static void SHA1Transform(php_hash_uint32 state[5], const unsigned char block[64
state[4] += e;
/* Zeroize sensitive information. */
- memset((unsigned char*) x, 0, sizeof(x));
+ ZEND_SECURE_ZERO((unsigned char*) x, sizeof(x));
}
/* }}} */
@@ -400,7 +400,7 @@ PHP_HASH_API void PHP_SHA1Final(unsigned char digest[20], PHP_SHA1_CTX * context
/* Zeroize sensitive information.
*/
- memset((unsigned char*) context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO((unsigned char*) context, sizeof(*context));
}
/* }}} */
@@ -511,7 +511,7 @@ static void SHA256Transform(php_hash_uint32 state[8], const unsigned char block[
state[7] += h;
/* Zeroize sensitive information. */
- memset((unsigned char*) x, 0, sizeof(x));
+ ZEND_SECURE_ZERO((unsigned char*) x, sizeof(x));
}
/* }}} */
@@ -607,7 +607,7 @@ PHP_HASH_API void PHP_SHA224Final(unsigned char digest[28], PHP_SHA224_CTX * con
/* Zeroize sensitive information.
*/
- memset((unsigned char*) context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO((unsigned char*) context, sizeof(*context));
}
/* }}} */
@@ -684,7 +684,7 @@ PHP_HASH_API void PHP_SHA256Final(unsigned char digest[32], PHP_SHA256_CTX * con
/* Zeroize sensitive information.
*/
- memset((unsigned char*) context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO((unsigned char*) context, sizeof(*context));
}
/* }}} */
@@ -821,7 +821,7 @@ static void SHA512Transform(php_hash_uint64 state[8], const unsigned char block[
state[7] += h;
/* Zeroize sensitive information. */
- memset((unsigned char*) x, 0, sizeof(x));
+ ZEND_SECURE_ZERO((unsigned char*) x, sizeof(x));
}
/* }}} */
@@ -906,7 +906,7 @@ PHP_HASH_API void PHP_SHA384Final(unsigned char digest[48], PHP_SHA384_CTX * con
/* Zeroize sensitive information.
*/
- memset((unsigned char*) context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO((unsigned char*) context, sizeof(*context));
}
/* }}} */
@@ -1020,7 +1020,7 @@ PHP_HASH_API void PHP_SHA512Final(unsigned char digest[64], PHP_SHA512_CTX * con
/* Zeroize sensitive information.
*/
- memset((unsigned char*) context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO((unsigned char*) context, sizeof(*context));
}
/* }}} */
diff --git a/ext/hash/hash_snefru.c b/ext/hash/hash_snefru.c
index 2cf37998ad..c35fee3c29 100644
--- a/ext/hash/hash_snefru.c
+++ b/ext/hash/hash_snefru.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -166,7 +166,7 @@ PHP_HASH_API void PHP_SNEFRUUpdate(PHP_SNEFRU_CTX *context, const unsigned char
}
memcpy(context->buffer, input + i, r);
- memset(&context->buffer[r], 0, 32 - r);
+ ZEND_SECURE_ZERO(&context->buffer[r], 32 - r);
context->length = r;
}
}
@@ -190,7 +190,7 @@ PHP_HASH_API void PHP_SNEFRUFinal(unsigned char digest[32], PHP_SNEFRU_CTX *cont
digest[j + 3] = (unsigned char) (context->state[i] & 0xff);
}
- memset(context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO(context, sizeof(*context));
}
const php_hash_ops php_hash_snefru_ops = {
diff --git a/ext/hash/hash_tiger.c b/ext/hash/hash_tiger.c
index 78f932a745..78f42b3ec7 100644
--- a/ext/hash/hash_tiger.c
+++ b/ext/hash/hash_tiger.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -207,7 +207,7 @@ PHP_HASH_API void PHP_TIGERUpdate(PHP_TIGER_CTX *context, const unsigned char *i
i = 64 - context->length;
memcpy(&context->buffer[context->length], input, i);
tiger_compress(context->passes, ((const php_hash_uint64 *) context->buffer), context->state);
- memset(context->buffer, 0, 64);
+ ZEND_SECURE_ZERO(context->buffer, 64);
context->passed += 512;
}
@@ -216,7 +216,7 @@ PHP_HASH_API void PHP_TIGERUpdate(PHP_TIGER_CTX *context, const unsigned char *i
tiger_compress(context->passes, ((const php_hash_uint64 *) context->buffer), context->state);
context->passed += 512;
}
- memset(&context->buffer[r], 0, 64-r);
+ ZEND_SECURE_ZERO(&context->buffer[r], 64-r);
memcpy(context->buffer, &input[i], r);
context->length = r;
}
@@ -226,21 +226,21 @@ PHP_HASH_API void PHP_TIGER128Final(unsigned char digest[16], PHP_TIGER_CTX *con
{
TigerFinalize(context);
TigerDigest(digest, 16, context);
- memset(context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO(context, sizeof(*context));
}
PHP_HASH_API void PHP_TIGER160Final(unsigned char digest[20], PHP_TIGER_CTX *context)
{
TigerFinalize(context);
TigerDigest(digest, 20, context);
- memset(context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO(context, sizeof(*context));
}
PHP_HASH_API void PHP_TIGER192Final(unsigned char digest[24], PHP_TIGER_CTX *context)
{
TigerFinalize(context);
TigerDigest(digest, 24, context);
- memset(context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO(context, sizeof(*context));
}
#define PHP_HASH_TIGER_OPS(p, b) \
diff --git a/ext/hash/hash_whirlpool.c b/ext/hash/hash_whirlpool.c
index ca41e523d0..b20dc82c17 100644
--- a/ext/hash/hash_whirlpool.c
+++ b/ext/hash/hash_whirlpool.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -263,8 +263,8 @@ static void WhirlpoolTransform(PHP_WHIRLPOOL_CTX *context)
context->state[5] ^= state[5] ^ block[5];
context->state[6] ^= state[6] ^ block[6];
context->state[7] ^= state[7] ^ block[7];
-
- memset(state, 0, sizeof(state));
+
+ ZEND_SECURE_ZERO(state, sizeof(state));
}
PHP_HASH_API void PHP_WHIRLPOOLInit(PHP_WHIRLPOOL_CTX *context)
@@ -430,7 +430,7 @@ PHP_HASH_API void PHP_WHIRLPOOLFinal(unsigned char digest[64], PHP_WHIRLPOOL_CTX
digest += 8;
}
- memset(context, 0, sizeof(*context));
+ ZEND_SECURE_ZERO(context, sizeof(*context));
}
const php_hash_ops php_hash_whirlpool_ops = {
diff --git a/ext/hash/php_hash.h b/ext/hash/php_hash.h
index d6905cfbd5..0fd0490f61 100644
--- a/ext/hash/php_hash.h
+++ b/ext/hash/php_hash.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/hash/php_hash_adler32.h b/ext/hash/php_hash_adler32.h
index ca78b38a13..73ef1067a1 100644
--- a/ext/hash/php_hash_adler32.h
+++ b/ext/hash/php_hash_adler32.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/hash/php_hash_crc32.h b/ext/hash/php_hash_crc32.h
index cc61243c30..fbd39e93df 100644
--- a/ext/hash/php_hash_crc32.h
+++ b/ext/hash/php_hash_crc32.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/hash/php_hash_crc32_tables.h b/ext/hash/php_hash_crc32_tables.h
index 30f5602287..889e4f667f 100644
--- a/ext/hash/php_hash_crc32_tables.h
+++ b/ext/hash/php_hash_crc32_tables.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/hash/php_hash_fnv.h b/ext/hash/php_hash_fnv.h
index 10023fc618..40005f2ead 100644
--- a/ext/hash/php_hash_fnv.h
+++ b/ext/hash/php_hash_fnv.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/hash/php_hash_gost.h b/ext/hash/php_hash_gost.h
index cd3f9cfe90..f1fda06c72 100644
--- a/ext/hash/php_hash_gost.h
+++ b/ext/hash/php_hash_gost.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/hash/php_hash_haval.h b/ext/hash/php_hash_haval.h
index 4a37815daf..1fafe5742e 100644
--- a/ext/hash/php_hash_haval.h
+++ b/ext/hash/php_hash_haval.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/hash/php_hash_joaat.h b/ext/hash/php_hash_joaat.h
index 494e7eb09a..d722efcae6 100644
--- a/ext/hash/php_hash_joaat.h
+++ b/ext/hash/php_hash_joaat.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/hash/php_hash_md.h b/ext/hash/php_hash_md.h
index 473abee66c..cfb696a323 100644
--- a/ext/hash/php_hash_md.h
+++ b/ext/hash/php_hash_md.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/hash/php_hash_ripemd.h b/ext/hash/php_hash_ripemd.h
index b564b3a17c..8eae0107b3 100644
--- a/ext/hash/php_hash_ripemd.h
+++ b/ext/hash/php_hash_ripemd.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/hash/php_hash_sha.h b/ext/hash/php_hash_sha.h
index bd24fb0974..6517619f17 100644
--- a/ext/hash/php_hash_sha.h
+++ b/ext/hash/php_hash_sha.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/hash/php_hash_snefru.h b/ext/hash/php_hash_snefru.h
index 214edb1982..d36e34df47 100644
--- a/ext/hash/php_hash_snefru.h
+++ b/ext/hash/php_hash_snefru.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/hash/php_hash_snefru_tables.h b/ext/hash/php_hash_snefru_tables.h
index ef92453031..89fae8bd69 100644
--- a/ext/hash/php_hash_snefru_tables.h
+++ b/ext/hash/php_hash_snefru_tables.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/hash/php_hash_tiger.h b/ext/hash/php_hash_tiger.h
index fd602d6819..f8d6a738d7 100644
--- a/ext/hash/php_hash_tiger.h
+++ b/ext/hash/php_hash_tiger.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/hash/php_hash_tiger_tables.h b/ext/hash/php_hash_tiger_tables.h
index f3e726f80c..3cf9846803 100644
--- a/ext/hash/php_hash_tiger_tables.h
+++ b/ext/hash/php_hash_tiger_tables.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/hash/php_hash_whirlpool.h b/ext/hash/php_hash_whirlpool.h
index d28b1d927c..15882c6a07 100644
--- a/ext/hash/php_hash_whirlpool.h
+++ b/ext/hash/php_hash_whirlpool.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/hash/php_hash_whirlpool_tables.h b/ext/hash/php_hash_whirlpool_tables.h
index 4951636003..4599f82444 100644
--- a/ext/hash/php_hash_whirlpool_tables.h
+++ b/ext/hash/php_hash_whirlpool_tables.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/iconv/iconv.c b/ext/iconv/iconv.c
index e1bf9deede..d425f6cf1e 100644
--- a/ext/iconv/iconv.c
+++ b/ext/iconv/iconv.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -55,7 +55,7 @@
#undef iconv
#endif
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#include "ext/standard/base64.h"
#include "ext/standard/quot_print.h"
@@ -415,7 +415,7 @@ static int php_iconv_output_handler(void **nothing, php_output_context *output_c
}
if (mimetype != NULL && !(output_context->op & PHP_OUTPUT_HANDLER_CLEAN)) {
- zend_long len;
+ size_t len;
char *p = strstr(get_output_encoding(TSRMLS_C), "//");
if (p) {
@@ -462,10 +462,7 @@ static php_iconv_err_t _php_iconv_appendl(smart_str *d, const char *s, size_t l,
if (in_p != NULL) {
while (in_left > 0) {
out_left = buf_growth - out_left;
- {
- size_t newlen;
- smart_str_alloc((d), out_left, 0);
- }
+ smart_str_alloc(d, out_left, 0);
out_p = (d)->s->val + (d)->s->len;
@@ -499,10 +496,7 @@ static php_iconv_err_t _php_iconv_appendl(smart_str *d, const char *s, size_t l,
} else {
for (;;) {
out_left = buf_growth - out_left;
- {
- size_t newlen;
- smart_str_alloc((d), out_left, 0);
- }
+ smart_str_alloc(d, out_left, 0);
out_p = (d)->s->val + (d)->s->len;
@@ -805,7 +799,7 @@ static php_iconv_err_t _php_iconv_substr(smart_str *pretval,
size_t out_left;
size_t cnt;
- zend_long total_len;
+ size_t total_len;
err = _php_iconv_strlen(&total_len, str, nbytes, enc);
if (err != PHP_ICONV_ERR_SUCCESS) {
@@ -824,16 +818,16 @@ static php_iconv_err_t _php_iconv_substr(smart_str *pretval,
}
}
- if(len > total_len) {
+ if((size_t)len > total_len) {
len = total_len;
}
- if (offset >= total_len) {
+ if ((size_t)offset >= total_len) {
return PHP_ICONV_ERR_SUCCESS;
}
- if ((offset + len) > total_len ) {
+ if ((size_t)(offset + len) > total_len ) {
/* trying to compute the length */
len = total_len - offset;
}
@@ -2076,7 +2070,7 @@ PHP_FUNCTION(iconv_substr)
err = _php_iconv_substr(&retval, str->val, str->len, offset, length, charset);
_php_iconv_show_error(err, GENERIC_SUPERSET_NAME, charset TSRMLS_CC);
- if (err == PHP_ICONV_ERR_SUCCESS && str->val != NULL && retval.s != NULL) {
+ if (err == PHP_ICONV_ERR_SUCCESS && str->val[0] != '\0' && retval.s != NULL) {
RETURN_STR(retval.s);
}
smart_str_free(&retval);
@@ -2761,7 +2755,7 @@ static int php_iconv_stream_filter_append_bucket(
prev_ocnt = ocnt;
}
- if (out_buf_size - ocnt > 0) {
+ if (out_buf_size > ocnt) {
if (NULL == (new_bucket = php_stream_bucket_new(stream, out_buf, (out_buf_size - ocnt), 1, persistent TSRMLS_CC))) {
goto out_failure;
}
diff --git a/ext/iconv/iconv.dsp b/ext/iconv/iconv.dsp
deleted file mode 100644
index 2d66cf00ab..0000000000
--- a/ext/iconv/iconv.dsp
+++ /dev/null
@@ -1,107 +0,0 @@
-# Microsoft Developer Studio Project File - Name="iconv" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=iconv - Win32 Debug_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "iconv.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "iconv.mak" CFG="iconv - Win32 Debug_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "iconv - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "iconv - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "iconv - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ICONV_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /I "..\..\win32" /I "..\..\..\php_build\iconv\include" /D "WIN32" /D "PHP_EXPORTS" /D "COMPILE_DL_ICONV" /D "HAVE_ICONV" /D ZEND_DEBUG=0 /D "NDEBUG" /D "_WINDOWS" /D "ZEND_WIN32" /D "PHP_WIN32" /D ZTS=1 /D "ICONV_SUPPORTS_ERRNO" /D "HAVE_LIBICONV" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "NDEBUG"
-# ADD RSC /l 0x407 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 php5ts.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_iconv.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-
-!ELSEIF "$(CFG)" == "iconv - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ICONV_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /I "..\..\win32" /I "..\..\..\php_build\iconv\include" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "PHP_EXPORTS" /D "COMPILE_DL_ICONV" /D "ZEND_WIN32" /D "PHP_WIN32" /D "HAVE_ICONV" /D ZTS=1 /D "HAVE_LIBICONV" /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "_DEBUG"
-# ADD RSC /l 0x407 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 php5ts_debug.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_iconv.dll" /pdbtype:sept /libpath:"..\..\Debug_TS"
-
-!ENDIF
-
-# Begin Target
-
-# Name "iconv - Win32 Release_TS"
-# Name "iconv - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\iconv.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_iconv.h
-# End Source File
-# End Group
-# End Target
-# End Project
diff --git a/ext/iconv/php_iconv.h b/ext/iconv/php_iconv.h
index 76e6758588..1a8330ae24 100644
--- a/ext/iconv/php_iconv.h
+++ b/ext/iconv/php_iconv.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/imap/imap.dsp b/ext/imap/imap.dsp
deleted file mode 100644
index ef05d49f20..0000000000
--- a/ext/imap/imap.dsp
+++ /dev/null
@@ -1,176 +0,0 @@
-# Microsoft Developer Studio Project File - Name="imap" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=imap - Win32 Debug_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "imap.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "imap.mak" CFG="imap - Win32 Debug_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "imap - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "imap - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "imap - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "imap - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "imap - Win32 Release"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release"
-# PROP BASE Intermediate_Dir "Release"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release"
-# PROP Intermediate_Dir "Release"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "IMAP_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\php_build\IMAP\c-client" /I "..\..\TSRM" /D "NDEBUG" /D "IMAP_EXPORTS" /D "COMPILE_DL_IMAP" /D HAVE_IMAP=1 /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ZEND_WIN32" /D "PHP_WIN32" /D ZEND_DEBUG=0 /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x40d /d "NDEBUG"
-# ADD RSC /l 0x40d /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5nts.lib wsock32.lib winmm.lib cclient.lib /nologo /dll /machine:I386 /out:"Release/php_imap.dll" /libpath:"..\..\Release" /libpath:"..\..\..\php_build\IMAP\C-Client"
-
-!ELSEIF "$(CFG)" == "imap - Win32 Debug"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug"
-# PROP BASE Intermediate_Dir "Debug"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug"
-# PROP Intermediate_Dir "Debug"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "IMAP_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\php_build\IMAP\c-client" /I "..\..\TSRM" /D "_DEBUG" /D "IMAP_EXPORTS" /D "COMPILE_DL_IMAP" /D HAVE_IMAP=1 /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ZEND_WIN32" /D "PHP_WIN32" /D ZEND_DEBUG=1 /FR /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x40d /d "_DEBUG"
-# ADD RSC /l 0x40d /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5nts_debug.lib wsock32.lib winmm.lib cclient.lib /nologo /dll /debug /machine:I386 /out:"Debug/php_imap.dll" /pdbtype:sept /libpath:"..\..\Debug" /libpath:"..\..\..\php_build\IMAP\C-Client"
-
-!ELSEIF "$(CFG)" == "imap - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "IMAP_EXPORTS" /FR /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\..\\" /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /D "ZTS" /D "_DEBUG" /D "IMAP_EXPORTS" /D "COMPILE_DL_IMAP" /D HAVE_IMAP=1 /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ZEND_WIN32" /D "PHP_WIN32" /D ZEND_DEBUG=1 /FR /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x40d /d "_DEBUG"
-# ADD RSC /l 0x40d /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts_debug.lib wsock32.lib winmm.lib cclient.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_imap.dll" /pdbtype:sept /libpath:"..\..\..\\" /libpath:"..\..\Debug_TS"
-
-!ELSEIF "$(CFG)" == "imap - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "IMAP_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\..\\" /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\php_build\imap\c-client" /D "ZTS" /D "NDEBUG" /D "IMAP_EXPORTS" /D "COMPILE_DL_IMAP" /D HAVE_IMAP=1 /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ZEND_WIN32" /D "PHP_WIN32" /D ZEND_DEBUG=0 /D HAVE_IMAP2001=1 /FR /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x40d /d "NDEBUG"
-# ADD RSC /l 0x40d /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib wsock32.lib winmm.lib cclient.lib Secur32.lib CertIdl.Lib /nologo /dll /machine:I386 /nodefaultlib:"LIBCMT" /out:"..\..\Release_TS/php_imap.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline" /libpath:"..\..\..\php_build\imap"
-# SUBTRACT LINK32 /nodefaultlib
-
-!ENDIF
-
-# Begin Target
-
-# Name "imap - Win32 Release"
-# Name "imap - Win32 Debug"
-# Name "imap - Win32 Debug_TS"
-# Name "imap - Win32 Release_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\php_imap.c
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\win32\sendmail.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_imap.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\win32\sendmail.h
-# End Source File
-# End Group
-# Begin Source File
-
-SOURCE=.\IMAP_Win32_HOWTO.txt
-# End Source File
-# End Target
-# End Project
diff --git a/ext/imap/php_imap.c b/ext/imap/php_imap.c
index 3969a036fc..8dc56c5223 100644
--- a/ext/imap/php_imap.c
+++ b/ext/imap/php_imap.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -40,7 +40,7 @@
#include "ext/standard/php_string.h"
#include "ext/standard/info.h"
#include "ext/standard/file.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#include "ext/pcre/php_pcre.h"
#ifdef ERROR
diff --git a/ext/imap/php_imap.h b/ext/imap/php_imap.h
index a823326cca..6f18181b53 100644
--- a/ext/imap/php_imap.h
+++ b/ext/imap/php_imap.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/interbase/ibase_blobs.c b/ext/interbase/ibase_blobs.c
index b188e54e4f..6ac44ffeb0 100644
--- a/ext/interbase/ibase_blobs.c
+++ b/ext/interbase/ibase_blobs.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/interbase/ibase_events.c b/ext/interbase/ibase_events.c
index 63a838679d..5a64b31c75 100644
--- a/ext/interbase/ibase_events.c
+++ b/ext/interbase/ibase_events.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/interbase/ibase_query.c b/ext/interbase/ibase_query.c
index 10d77449dc..2cd2ada65f 100644
--- a/ext/interbase/ibase_query.c
+++ b/ext/interbase/ibase_query.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/interbase/ibase_service.c b/ext/interbase/ibase_service.c
index bdbec7d5b0..c068c8d56b 100644
--- a/ext/interbase/ibase_service.c
+++ b/ext/interbase/ibase_service.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/interbase/interbase.c b/ext/interbase/interbase.c
index a21e6469fa..59c4a0fa42 100644
--- a/ext/interbase/interbase.c
+++ b/ext/interbase/interbase.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/interbase/interbase.dsp b/ext/interbase/interbase.dsp
deleted file mode 100644
index c151deb40c..0000000000
--- a/ext/interbase/interbase.dsp
+++ /dev/null
@@ -1,135 +0,0 @@
-# Microsoft Developer Studio Project File - Name="interbase" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=interbase - Win32 Debug_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "interbase.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "interbase.mak" CFG="interbase - Win32 Debug_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "interbase - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "interbase - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName "interbase"
-# PROP Scc_LocalPath "."
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "interbase - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\..\main" /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\..\php_build\Interbase SDK\include" /D "_DEBUG" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "INTERBASE_EXPORTS" /D "ZEND_WIN32" /D "PHP_WIN32" /D ZEND_DEBUG=1 /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\..\main" /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\..\php_build\Interbase SDK\include" /I "..\..\..\bindlib_w32" /D "_DEBUG" /D ZEND_DEBUG=1 /D "ZTS" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "INTERBASE_EXPORTS" /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_IBASE=1 /D "COMPILE_DL_INTERBASE" /FR /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x40d /d "_DEBUG"
-# ADD RSC /l 0x40d /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib ib_util_ms.lib gds32_ms.lib php5ts_debug.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts_debug.lib gds32_ms.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_interbase.dll" /pdbtype:sept /libpath:"..\..\..\php_build\Interbase SDK\lib_ms" /libpath:"..\..\Debug_TS"
-
-!ELSEIF "$(CFG)" == "interbase - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MD /W3 /GX /O2 /I "..\..\main" /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\..\php_build\Interbase SDK\include" /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "INTERBASE_EXPORTS" /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_IBASE=1 /D ZEND_DEBUG=0 /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\..\main" /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\..\php_build\Interbase SDK\include" /I "..\..\..\bindlib_w32" /D "NDEBUG" /D ZEND_DEBUG=0 /D "ZTS" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "INTERBASE_EXPORTS" /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_IBASE=1 /D "COMPILE_DL_INTERBASE" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x40d /d "NDEBUG"
-# ADD RSC /l 0x40d /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 php5ts.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib ib_util_ms.lib gds32_ms.lib /nologo /dll /machine:I386
-# ADD LINK32 php5ts.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib gds32_ms.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_interbase.dll" /libpath:"..\..\..\php_build\Interbase SDK\lib_ms" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-
-!ENDIF
-
-# Begin Target
-
-# Name "interbase - Win32 Debug_TS"
-# Name "interbase - Win32 Release_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\ibase_blobs.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\ibase_events.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\ibase_query.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\ibase_service.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\interbase.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_interbase.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# Begin Source File
-
-SOURCE=.\interbase.rc
-# ADD BASE RSC /l 0x413
-# ADD RSC /l 0x413 /i "..\..\main" /i "..\..\win32" /d "PHP_H"
-# End Source File
-# End Group
-# End Target
-# End Project
diff --git a/ext/interbase/php_ibase_includes.h b/ext/interbase/php_ibase_includes.h
index a51f44c034..8e80505c17 100644
--- a/ext/interbase/php_ibase_includes.h
+++ b/ext/interbase/php_ibase_includes.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/interbase/php_ibase_udf.c b/ext/interbase/php_ibase_udf.c
index 5a53df8b6b..4b47fbcfb6 100644
--- a/ext/interbase/php_ibase_udf.c
+++ b/ext/interbase/php_ibase_udf.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -84,7 +84,7 @@
*
* gcc -shared `php-config --includes` `php-config --ldflags` \
* `php-config --libs` -o php_ibase_udf.so php_ibase_udf.c \
-* /usr/lib/libphp5.a
+* /usr/lib/libphp7.a
*
* If you use the super server, you should also link against the embedded
* library, but be sure to enable thread safety, as the super server is
@@ -404,4 +404,3 @@ void udf_call_php8(char *name, PARAMDSC *r, PARAMDSC *arg1, PARAMDSC *arg2, PARA
PARAMDSC *args[8] = { arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8 };
call_php(name, r, 8, args);
}
-
diff --git a/ext/interbase/php_interbase.h b/ext/interbase/php_interbase.h
index 0518b586f9..c8afc8df8f 100644
--- a/ext/interbase/php_interbase.h
+++ b/ext/interbase/php_interbase.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/intl/breakiterator/breakiterator_class.cpp b/ext/intl/breakiterator/breakiterator_class.cpp
index ea3a305dd9..715a866111 100644
--- a/ext/intl/breakiterator/breakiterator_class.cpp
+++ b/ext/intl/breakiterator/breakiterator_class.cpp
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/breakiterator/breakiterator_class.h b/ext/intl/breakiterator/breakiterator_class.h
index 0cf213f260..6333003981 100644
--- a/ext/intl/breakiterator/breakiterator_class.h
+++ b/ext/intl/breakiterator/breakiterator_class.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/breakiterator/breakiterator_iterators.cpp b/ext/intl/breakiterator/breakiterator_iterators.cpp
index d8f18f99f3..19de7bce34 100644
--- a/ext/intl/breakiterator/breakiterator_iterators.cpp
+++ b/ext/intl/breakiterator/breakiterator_iterators.cpp
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/breakiterator/breakiterator_iterators.h b/ext/intl/breakiterator/breakiterator_iterators.h
index a955f3a8e7..764f4f4426 100644
--- a/ext/intl/breakiterator/breakiterator_iterators.h
+++ b/ext/intl/breakiterator/breakiterator_iterators.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/breakiterator/breakiterator_methods.cpp b/ext/intl/breakiterator/breakiterator_methods.cpp
index cb5f669d05..1153340e14 100644
--- a/ext/intl/breakiterator/breakiterator_methods.cpp
+++ b/ext/intl/breakiterator/breakiterator_methods.cpp
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/breakiterator/breakiterator_methods.h b/ext/intl/breakiterator/breakiterator_methods.h
index bc9ce80105..cffe767c55 100644
--- a/ext/intl/breakiterator/breakiterator_methods.h
+++ b/ext/intl/breakiterator/breakiterator_methods.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/breakiterator/codepointiterator_internal.cpp b/ext/intl/breakiterator/codepointiterator_internal.cpp
index bffd1ee5cf..723cfd5022 100644
--- a/ext/intl/breakiterator/codepointiterator_internal.cpp
+++ b/ext/intl/breakiterator/codepointiterator_internal.cpp
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/breakiterator/codepointiterator_internal.h b/ext/intl/breakiterator/codepointiterator_internal.h
index 933347b859..0c9b8cc9a5 100644
--- a/ext/intl/breakiterator/codepointiterator_internal.h
+++ b/ext/intl/breakiterator/codepointiterator_internal.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/breakiterator/codepointiterator_methods.cpp b/ext/intl/breakiterator/codepointiterator_methods.cpp
index a833cf1853..d7fe359712 100644
--- a/ext/intl/breakiterator/codepointiterator_methods.cpp
+++ b/ext/intl/breakiterator/codepointiterator_methods.cpp
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/breakiterator/codepointiterator_methods.h b/ext/intl/breakiterator/codepointiterator_methods.h
index ad3b710fc8..92f255d704 100644
--- a/ext/intl/breakiterator/codepointiterator_methods.h
+++ b/ext/intl/breakiterator/codepointiterator_methods.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/breakiterator/rulebasedbreakiterator_methods.cpp b/ext/intl/breakiterator/rulebasedbreakiterator_methods.cpp
index 74bebb2db2..d3b36291b2 100644
--- a/ext/intl/breakiterator/rulebasedbreakiterator_methods.cpp
+++ b/ext/intl/breakiterator/rulebasedbreakiterator_methods.cpp
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/breakiterator/rulebasedbreakiterator_methods.h b/ext/intl/breakiterator/rulebasedbreakiterator_methods.h
index 861ca4253f..3a9209c479 100644
--- a/ext/intl/breakiterator/rulebasedbreakiterator_methods.h
+++ b/ext/intl/breakiterator/rulebasedbreakiterator_methods.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/calendar/calendar_class.cpp b/ext/intl/calendar/calendar_class.cpp
index 58375f8196..7273b1d277 100644
--- a/ext/intl/calendar/calendar_class.cpp
+++ b/ext/intl/calendar/calendar_class.cpp
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/calendar/calendar_class.h b/ext/intl/calendar/calendar_class.h
index 2e7fbd2172..47f991f118 100644
--- a/ext/intl/calendar/calendar_class.h
+++ b/ext/intl/calendar/calendar_class.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/calendar/calendar_methods.cpp b/ext/intl/calendar/calendar_methods.cpp
index 168c791d36..eaa1930e42 100644
--- a/ext/intl/calendar/calendar_methods.cpp
+++ b/ext/intl/calendar/calendar_methods.cpp
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/calendar/calendar_methods.h b/ext/intl/calendar/calendar_methods.h
index dfd0bbeeaf..838917cac3 100644
--- a/ext/intl/calendar/calendar_methods.h
+++ b/ext/intl/calendar/calendar_methods.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/calendar/gregoriancalendar_methods.cpp b/ext/intl/calendar/gregoriancalendar_methods.cpp
index 790a0519cd..b0c8a964f6 100644
--- a/ext/intl/calendar/gregoriancalendar_methods.cpp
+++ b/ext/intl/calendar/gregoriancalendar_methods.cpp
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/calendar/gregoriancalendar_methods.h b/ext/intl/calendar/gregoriancalendar_methods.h
index f911752cc7..659566427c 100644
--- a/ext/intl/calendar/gregoriancalendar_methods.h
+++ b/ext/intl/calendar/gregoriancalendar_methods.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/collator/collator.c b/ext/intl/collator/collator.c
index eff9568de1..07dc6385c8 100644
--- a/ext/intl/collator/collator.c
+++ b/ext/intl/collator/collator.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/collator/collator.h b/ext/intl/collator/collator.h
index 96e7aa097b..ea0071b179 100644
--- a/ext/intl/collator/collator.h
+++ b/ext/intl/collator/collator.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/collator/collator_attr.c b/ext/intl/collator/collator_attr.c
index 72446f51a7..8d879de8f7 100644
--- a/ext/intl/collator/collator_attr.c
+++ b/ext/intl/collator/collator_attr.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/collator/collator_attr.h b/ext/intl/collator/collator_attr.h
index 85636cc486..b86365ff5e 100644
--- a/ext/intl/collator/collator_attr.h
+++ b/ext/intl/collator/collator_attr.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/collator/collator_class.c b/ext/intl/collator/collator_class.c
index 25a3ac8909..fd3f08e359 100644
--- a/ext/intl/collator/collator_class.c
+++ b/ext/intl/collator/collator_class.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/collator/collator_class.h b/ext/intl/collator/collator_class.h
index 8410e96646..f9d2cedf88 100644
--- a/ext/intl/collator/collator_class.h
+++ b/ext/intl/collator/collator_class.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/collator/collator_compare.c b/ext/intl/collator/collator_compare.c
index 444b1fc4fd..d27ff32ebd 100644
--- a/ext/intl/collator/collator_compare.c
+++ b/ext/intl/collator/collator_compare.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/collator/collator_compare.h b/ext/intl/collator/collator_compare.h
index 4e38b79309..cca9ca29b1 100644
--- a/ext/intl/collator/collator_compare.h
+++ b/ext/intl/collator/collator_compare.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/collator/collator_convert.c b/ext/intl/collator/collator_convert.c
index 5a572067f6..bc279b25f7 100644
--- a/ext/intl/collator/collator_convert.c
+++ b/ext/intl/collator/collator_convert.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/collator/collator_convert.h b/ext/intl/collator/collator_convert.h
index 7e169d559e..bf116bdfd8 100644
--- a/ext/intl/collator/collator_convert.h
+++ b/ext/intl/collator/collator_convert.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/collator/collator_create.c b/ext/intl/collator/collator_create.c
index a1b2aa743a..3c59f218e6 100644
--- a/ext/intl/collator/collator_create.c
+++ b/ext/intl/collator/collator_create.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/collator/collator_create.h b/ext/intl/collator/collator_create.h
index b740e82d68..b5e9489e3d 100644
--- a/ext/intl/collator/collator_create.h
+++ b/ext/intl/collator/collator_create.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/collator/collator_error.c b/ext/intl/collator/collator_error.c
index 91bc25d077..fb8886ef64 100644
--- a/ext/intl/collator/collator_error.c
+++ b/ext/intl/collator/collator_error.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/collator/collator_error.h b/ext/intl/collator/collator_error.h
index b2f44ea2a3..3c8c10a043 100644
--- a/ext/intl/collator/collator_error.h
+++ b/ext/intl/collator/collator_error.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/collator/collator_is_numeric.c b/ext/intl/collator/collator_is_numeric.c
index db9e41f887..a93cd962f3 100644
--- a/ext/intl/collator/collator_is_numeric.c
+++ b/ext/intl/collator/collator_is_numeric.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/collator/collator_is_numeric.h b/ext/intl/collator/collator_is_numeric.h
index d7aa12ce46..5ede4fa922 100644
--- a/ext/intl/collator/collator_is_numeric.h
+++ b/ext/intl/collator/collator_is_numeric.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/collator/collator_locale.c b/ext/intl/collator/collator_locale.c
index dd37cc75db..76f154bb7c 100644
--- a/ext/intl/collator/collator_locale.c
+++ b/ext/intl/collator/collator_locale.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/collator/collator_locale.h b/ext/intl/collator/collator_locale.h
index bda90cd3b9..b2f837b49a 100644
--- a/ext/intl/collator/collator_locale.h
+++ b/ext/intl/collator/collator_locale.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/collator/collator_sort.c b/ext/intl/collator/collator_sort.c
index 1ec72e3a73..4fd7c4597e 100644
--- a/ext/intl/collator/collator_sort.c
+++ b/ext/intl/collator/collator_sort.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
@@ -203,7 +203,7 @@ static int collator_icu_compare_function(zval *result, zval *op1, zval *op2 TSRM
/* }}} */
/* {{{ collator_compare_func
- * Taken from PHP5 source (array_data_compare).
+ * Taken from PHP7 source (array_data_compare).
*/
static int collator_compare_func( const void* a, const void* b TSRMLS_DC )
{
diff --git a/ext/intl/collator/collator_sort.h b/ext/intl/collator/collator_sort.h
index a990cdf089..b5cb017a8c 100644
--- a/ext/intl/collator/collator_sort.h
+++ b/ext/intl/collator/collator_sort.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/common/common_date.cpp b/ext/intl/common/common_date.cpp
index 783611e02f..23dc342080 100644
--- a/ext/intl/common/common_date.cpp
+++ b/ext/intl/common/common_date.cpp
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/common/common_date.h b/ext/intl/common/common_date.h
index d2396cbf5a..e8ab66f40d 100644
--- a/ext/intl/common/common_date.h
+++ b/ext/intl/common/common_date.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/common/common_enum.cpp b/ext/intl/common/common_enum.cpp
index ff28bdb456..952b39edca 100644
--- a/ext/intl/common/common_enum.cpp
+++ b/ext/intl/common/common_enum.cpp
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/common/common_enum.h b/ext/intl/common/common_enum.h
index 2b6d1790d9..af46a47751 100644
--- a/ext/intl/common/common_enum.h
+++ b/ext/intl/common/common_enum.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/common/common_error.c b/ext/intl/common/common_error.c
index f7b739555e..524bb94327 100644
--- a/ext/intl/common/common_error.c
+++ b/ext/intl/common/common_error.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/common/common_error.h b/ext/intl/common/common_error.h
index 8716222124..46a26793ee 100644
--- a/ext/intl/common/common_error.h
+++ b/ext/intl/common/common_error.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/converter/converter.c b/ext/intl/converter/converter.c
index 887c404271..b27652aa9a 100644
--- a/ext/intl/converter/converter.c
+++ b/ext/intl/converter/converter.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/converter/converter.h b/ext/intl/converter/converter.h
index bd316fcf98..520c7c6c86 100644
--- a/ext/intl/converter/converter.h
+++ b/ext/intl/converter/converter.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/dateformat/dateformat.c b/ext/intl/dateformat/dateformat.c
index eedc60040e..ffa606a9cd 100644
--- a/ext/intl/dateformat/dateformat.c
+++ b/ext/intl/dateformat/dateformat.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/dateformat/dateformat.h b/ext/intl/dateformat/dateformat.h
index f11918b79f..6139b67951 100644
--- a/ext/intl/dateformat/dateformat.h
+++ b/ext/intl/dateformat/dateformat.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/dateformat/dateformat_attr.c b/ext/intl/dateformat/dateformat_attr.c
index 0450ef1c37..314ae730c7 100644
--- a/ext/intl/dateformat/dateformat_attr.c
+++ b/ext/intl/dateformat/dateformat_attr.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/dateformat/dateformat_attr.h b/ext/intl/dateformat/dateformat_attr.h
index 6fe82a6e00..e7013a9e2a 100644
--- a/ext/intl/dateformat/dateformat_attr.h
+++ b/ext/intl/dateformat/dateformat_attr.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/dateformat/dateformat_attrcpp.cpp b/ext/intl/dateformat/dateformat_attrcpp.cpp
index 5f63d33143..71b136c6c1 100644
--- a/ext/intl/dateformat/dateformat_attrcpp.cpp
+++ b/ext/intl/dateformat/dateformat_attrcpp.cpp
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/dateformat/dateformat_attrcpp.h b/ext/intl/dateformat/dateformat_attrcpp.h
index 408232f940..54536f21fa 100644
--- a/ext/intl/dateformat/dateformat_attrcpp.h
+++ b/ext/intl/dateformat/dateformat_attrcpp.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/dateformat/dateformat_class.c b/ext/intl/dateformat/dateformat_class.c
index 4c46a7d694..0d93338ecd 100644
--- a/ext/intl/dateformat/dateformat_class.c
+++ b/ext/intl/dateformat/dateformat_class.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/dateformat/dateformat_class.h b/ext/intl/dateformat/dateformat_class.h
index a3eb4b9839..ebd057022e 100644
--- a/ext/intl/dateformat/dateformat_class.h
+++ b/ext/intl/dateformat/dateformat_class.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/dateformat/dateformat_create.cpp b/ext/intl/dateformat/dateformat_create.cpp
index 97997554a5..4a272aa45f 100644
--- a/ext/intl/dateformat/dateformat_create.cpp
+++ b/ext/intl/dateformat/dateformat_create.cpp
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/dateformat/dateformat_create.h b/ext/intl/dateformat/dateformat_create.h
index 47e67c2f45..c6e2d0feb8 100644
--- a/ext/intl/dateformat/dateformat_create.h
+++ b/ext/intl/dateformat/dateformat_create.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/dateformat/dateformat_data.c b/ext/intl/dateformat/dateformat_data.c
index 33451e1c51..509e91b617 100644
--- a/ext/intl/dateformat/dateformat_data.c
+++ b/ext/intl/dateformat/dateformat_data.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/dateformat/dateformat_data.h b/ext/intl/dateformat/dateformat_data.h
index cde9e363c9..a49da7dc89 100644
--- a/ext/intl/dateformat/dateformat_data.h
+++ b/ext/intl/dateformat/dateformat_data.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/dateformat/dateformat_format.c b/ext/intl/dateformat/dateformat_format.c
index dd9b64d4ee..d11eb2df24 100644
--- a/ext/intl/dateformat/dateformat_format.c
+++ b/ext/intl/dateformat/dateformat_format.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/dateformat/dateformat_format.h b/ext/intl/dateformat/dateformat_format.h
index 49f34c6892..02b773f991 100644
--- a/ext/intl/dateformat/dateformat_format.h
+++ b/ext/intl/dateformat/dateformat_format.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/dateformat/dateformat_format_object.cpp b/ext/intl/dateformat/dateformat_format_object.cpp
index 2b431383ff..b552ed7529 100644
--- a/ext/intl/dateformat/dateformat_format_object.cpp
+++ b/ext/intl/dateformat/dateformat_format_object.cpp
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/dateformat/dateformat_format_object.h b/ext/intl/dateformat/dateformat_format_object.h
index d80ea87e0f..f92296cd59 100644
--- a/ext/intl/dateformat/dateformat_format_object.h
+++ b/ext/intl/dateformat/dateformat_format_object.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/dateformat/dateformat_helpers.cpp b/ext/intl/dateformat/dateformat_helpers.cpp
index 92296be97a..b3f134a4f1 100644
--- a/ext/intl/dateformat/dateformat_helpers.cpp
+++ b/ext/intl/dateformat/dateformat_helpers.cpp
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/dateformat/dateformat_helpers.h b/ext/intl/dateformat/dateformat_helpers.h
index ca88da008a..c6121d75bb 100644
--- a/ext/intl/dateformat/dateformat_helpers.h
+++ b/ext/intl/dateformat/dateformat_helpers.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/dateformat/dateformat_parse.c b/ext/intl/dateformat/dateformat_parse.c
index 183ccb261c..15279da3a1 100644
--- a/ext/intl/dateformat/dateformat_parse.c
+++ b/ext/intl/dateformat/dateformat_parse.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/dateformat/dateformat_parse.h b/ext/intl/dateformat/dateformat_parse.h
index c74a3d5f15..694dbf8d90 100644
--- a/ext/intl/dateformat/dateformat_parse.h
+++ b/ext/intl/dateformat/dateformat_parse.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/formatter/formatter.c b/ext/intl/formatter/formatter.c
index 12cbb6c75b..bb4d3d2ac5 100644
--- a/ext/intl/formatter/formatter.c
+++ b/ext/intl/formatter/formatter.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/formatter/formatter.h b/ext/intl/formatter/formatter.h
index 1f9ebead8e..47ec473aae 100644
--- a/ext/intl/formatter/formatter.h
+++ b/ext/intl/formatter/formatter.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/formatter/formatter_attr.c b/ext/intl/formatter/formatter_attr.c
index 7278007c35..639342f4af 100644
--- a/ext/intl/formatter/formatter_attr.c
+++ b/ext/intl/formatter/formatter_attr.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/formatter/formatter_attr.h b/ext/intl/formatter/formatter_attr.h
index c4bc94ce5f..e8690ac8a4 100644
--- a/ext/intl/formatter/formatter_attr.h
+++ b/ext/intl/formatter/formatter_attr.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/formatter/formatter_class.c b/ext/intl/formatter/formatter_class.c
index 601aeae5e6..8fcc155e85 100644
--- a/ext/intl/formatter/formatter_class.c
+++ b/ext/intl/formatter/formatter_class.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/formatter/formatter_class.h b/ext/intl/formatter/formatter_class.h
index 12061ba5df..1db688712c 100644
--- a/ext/intl/formatter/formatter_class.h
+++ b/ext/intl/formatter/formatter_class.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/formatter/formatter_data.c b/ext/intl/formatter/formatter_data.c
index 88f122f7c9..2f785ba68f 100644
--- a/ext/intl/formatter/formatter_data.c
+++ b/ext/intl/formatter/formatter_data.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/formatter/formatter_data.h b/ext/intl/formatter/formatter_data.h
index adc4818afc..0e3bc4fea4 100644
--- a/ext/intl/formatter/formatter_data.h
+++ b/ext/intl/formatter/formatter_data.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/formatter/formatter_format.c b/ext/intl/formatter/formatter_format.c
index 1382b88d74..937cb05812 100644
--- a/ext/intl/formatter/formatter_format.c
+++ b/ext/intl/formatter/formatter_format.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/formatter/formatter_format.h b/ext/intl/formatter/formatter_format.h
index 35fafd1ede..af7b0ffe26 100644
--- a/ext/intl/formatter/formatter_format.h
+++ b/ext/intl/formatter/formatter_format.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/formatter/formatter_main.c b/ext/intl/formatter/formatter_main.c
index f7ac1b789f..939a8f782b 100644
--- a/ext/intl/formatter/formatter_main.c
+++ b/ext/intl/formatter/formatter_main.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/formatter/formatter_main.h b/ext/intl/formatter/formatter_main.h
index 7669e684ae..66cf5c1b6b 100644
--- a/ext/intl/formatter/formatter_main.h
+++ b/ext/intl/formatter/formatter_main.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/formatter/formatter_parse.c b/ext/intl/formatter/formatter_parse.c
index a84eecb2a9..0959d11830 100644
--- a/ext/intl/formatter/formatter_parse.c
+++ b/ext/intl/formatter/formatter_parse.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/formatter/formatter_parse.h b/ext/intl/formatter/formatter_parse.h
index cb96c72b5d..7a3098fcb2 100644
--- a/ext/intl/formatter/formatter_parse.h
+++ b/ext/intl/formatter/formatter_parse.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/grapheme/grapheme.h b/ext/intl/grapheme/grapheme.h
index 756ce9173e..5256a272a1 100644
--- a/ext/intl/grapheme/grapheme.h
+++ b/ext/intl/grapheme/grapheme.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/grapheme/grapheme_util.c b/ext/intl/grapheme/grapheme_util.c
index c752b02372..5e94eefc8a 100644
--- a/ext/intl/grapheme/grapheme_util.c
+++ b/ext/intl/grapheme/grapheme_util.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/grapheme/grapheme_util.h b/ext/intl/grapheme/grapheme_util.h
index 235d043818..a66796d80d 100644
--- a/ext/intl/grapheme/grapheme_util.h
+++ b/ext/intl/grapheme/grapheme_util.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/idn/idn.c b/ext/intl/idn/idn.c
index 99e484c17e..1d07dbba80 100644
--- a/ext/intl/idn/idn.c
+++ b/ext/intl/idn/idn.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2009 The PHP Group |
+----------------------------------------------------------------------+
@@ -184,7 +184,7 @@ static void php_intl_idn_to_46(INTERNAL_FUNCTION_PARAMETERS,
add_assoc_zval_ex(idna_info, "result", sizeof("result")-1, return_value);
} else {
zval zv;
- ZVAL_STR(&zv, buffer);
+ ZVAL_NEW_STR(&zv, buffer);
buffer_used = 1;
add_assoc_zval_ex(idna_info, "result", sizeof("result")-1, &zv);
}
diff --git a/ext/intl/idn/idn.h b/ext/intl/idn/idn.h
index 1fa4f8f2e5..1d49fe9f0a 100644
--- a/ext/intl/idn/idn.h
+++ b/ext/intl/idn/idn.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2009 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/intl/intl_common.h b/ext/intl/intl_common.h
index 9424571d02..a49794648d 100644
--- a/ext/intl/intl_common.h
+++ b/ext/intl/intl_common.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/intl_convert.c b/ext/intl/intl_convert.c
index 92cdc4cef4..7f756b9e7f 100644
--- a/ext/intl/intl_convert.c
+++ b/ext/intl/intl_convert.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/intl_convert.h b/ext/intl/intl_convert.h
index 3fc03f4bb7..952d765c52 100644
--- a/ext/intl/intl_convert.h
+++ b/ext/intl/intl_convert.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/intl_convertcpp.cpp b/ext/intl/intl_convertcpp.cpp
index f699a3c61c..f52348bc25 100644
--- a/ext/intl/intl_convertcpp.cpp
+++ b/ext/intl/intl_convertcpp.cpp
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/intl_convertcpp.h b/ext/intl/intl_convertcpp.h
index 89d4209dd3..fc2242a6b8 100644
--- a/ext/intl/intl_convertcpp.h
+++ b/ext/intl/intl_convertcpp.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/intl_cppshims.h b/ext/intl/intl_cppshims.h
index e58ec3bd45..e2db488d93 100644
--- a/ext/intl/intl_cppshims.h
+++ b/ext/intl/intl_cppshims.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/intl_data.h b/ext/intl/intl_data.h
index 1b764a2ab1..a7afb36be9 100644
--- a/ext/intl/intl_data.h
+++ b/ext/intl/intl_data.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/intl_error.c b/ext/intl/intl_error.c
index 5c082ce190..9474834417 100644
--- a/ext/intl/intl_error.c
+++ b/ext/intl/intl_error.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/intl_error.h b/ext/intl/intl_error.h
index 06f33a4bd3..b800d10dbf 100644
--- a/ext/intl/intl_error.h
+++ b/ext/intl/intl_error.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
@@ -21,7 +21,7 @@
#include <unicode/utypes.h>
#include <unicode/parseerr.h>
-#include <ext/standard/php_smart_str.h>
+#include <zend_smart_str.h>
#define INTL_ERROR_CODE(e) (e).code
diff --git a/ext/intl/locale/locale.c b/ext/intl/locale/locale.c
index 921e6e589f..21c875ca5d 100644
--- a/ext/intl/locale/locale.c
+++ b/ext/intl/locale/locale.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/locale/locale.h b/ext/intl/locale/locale.h
index f3859c7a2a..9118bee653 100644
--- a/ext/intl/locale/locale.h
+++ b/ext/intl/locale/locale.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/locale/locale_class.c b/ext/intl/locale/locale_class.c
index 432cfb28fc..eec4699b6d 100644
--- a/ext/intl/locale/locale_class.c
+++ b/ext/intl/locale/locale_class.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/locale/locale_class.h b/ext/intl/locale/locale_class.h
index cbddccbe17..afae06c77c 100644
--- a/ext/intl/locale/locale_class.h
+++ b/ext/intl/locale/locale_class.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/locale/locale_methods.c b/ext/intl/locale/locale_methods.c
index 4cafd02982..27f917ffbb 100644
--- a/ext/intl/locale/locale_methods.c
+++ b/ext/intl/locale/locale_methods.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
@@ -36,7 +36,7 @@
#include <zend.h>
#include <php.h>
#include "main/php_ini.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
ZEND_EXTERN_MODULE_GLOBALS( intl )
diff --git a/ext/intl/locale/locale_methods.h b/ext/intl/locale/locale_methods.h
index e88fac64b7..bc11975c18 100644
--- a/ext/intl/locale/locale_methods.h
+++ b/ext/intl/locale/locale_methods.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/msgformat/msgformat.c b/ext/intl/msgformat/msgformat.c
index b42d87967e..2ca8ed9186 100644
--- a/ext/intl/msgformat/msgformat.c
+++ b/ext/intl/msgformat/msgformat.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/msgformat/msgformat.h b/ext/intl/msgformat/msgformat.h
index 205c7066fd..a0b2c89644 100644
--- a/ext/intl/msgformat/msgformat.h
+++ b/ext/intl/msgformat/msgformat.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/msgformat/msgformat_attr.c b/ext/intl/msgformat/msgformat_attr.c
index 9359b796c3..79c04266e0 100644
--- a/ext/intl/msgformat/msgformat_attr.c
+++ b/ext/intl/msgformat/msgformat_attr.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/msgformat/msgformat_attr.h b/ext/intl/msgformat/msgformat_attr.h
index 898c4451e1..891f44c073 100644
--- a/ext/intl/msgformat/msgformat_attr.h
+++ b/ext/intl/msgformat/msgformat_attr.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/msgformat/msgformat_class.c b/ext/intl/msgformat/msgformat_class.c
index 71504bce2c..65f32bf683 100644
--- a/ext/intl/msgformat/msgformat_class.c
+++ b/ext/intl/msgformat/msgformat_class.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/msgformat/msgformat_class.h b/ext/intl/msgformat/msgformat_class.h
index 66b6ce18a5..8c2c29a7dd 100644
--- a/ext/intl/msgformat/msgformat_class.h
+++ b/ext/intl/msgformat/msgformat_class.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/msgformat/msgformat_data.c b/ext/intl/msgformat/msgformat_data.c
index 5d49054473..f94920d3e8 100644
--- a/ext/intl/msgformat/msgformat_data.c
+++ b/ext/intl/msgformat/msgformat_data.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/msgformat/msgformat_data.h b/ext/intl/msgformat/msgformat_data.h
index 3b7bdda78e..f3a594d25a 100644
--- a/ext/intl/msgformat/msgformat_data.h
+++ b/ext/intl/msgformat/msgformat_data.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/msgformat/msgformat_format.c b/ext/intl/msgformat/msgformat_format.c
index cb81137316..36cd61c685 100644
--- a/ext/intl/msgformat/msgformat_format.c
+++ b/ext/intl/msgformat/msgformat_format.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/msgformat/msgformat_format.h b/ext/intl/msgformat/msgformat_format.h
index b74deab8ff..12b0e4a283 100644
--- a/ext/intl/msgformat/msgformat_format.h
+++ b/ext/intl/msgformat/msgformat_format.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/msgformat/msgformat_helpers.cpp b/ext/intl/msgformat/msgformat_helpers.cpp
index c0c204cc69..46ebe25a17 100644
--- a/ext/intl/msgformat/msgformat_helpers.cpp
+++ b/ext/intl/msgformat/msgformat_helpers.cpp
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/msgformat/msgformat_helpers.h b/ext/intl/msgformat/msgformat_helpers.h
index f88fd4f06b..41d179f8d0 100644
--- a/ext/intl/msgformat/msgformat_helpers.h
+++ b/ext/intl/msgformat/msgformat_helpers.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/msgformat/msgformat_parse.c b/ext/intl/msgformat/msgformat_parse.c
index 516f493ec9..add2f901eb 100644
--- a/ext/intl/msgformat/msgformat_parse.c
+++ b/ext/intl/msgformat/msgformat_parse.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/msgformat/msgformat_parse.h b/ext/intl/msgformat/msgformat_parse.h
index a937235839..4a86403a48 100644
--- a/ext/intl/msgformat/msgformat_parse.h
+++ b/ext/intl/msgformat/msgformat_parse.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/normalizer/normalizer.c b/ext/intl/normalizer/normalizer.c
index f06a3e685c..18c3cedcaf 100644
--- a/ext/intl/normalizer/normalizer.c
+++ b/ext/intl/normalizer/normalizer.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/normalizer/normalizer.h b/ext/intl/normalizer/normalizer.h
index eca9abe05a..c057a51883 100644
--- a/ext/intl/normalizer/normalizer.h
+++ b/ext/intl/normalizer/normalizer.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/normalizer/normalizer_class.c b/ext/intl/normalizer/normalizer_class.c
index 154d877e3f..ccd8be3b29 100644
--- a/ext/intl/normalizer/normalizer_class.c
+++ b/ext/intl/normalizer/normalizer_class.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/normalizer/normalizer_class.h b/ext/intl/normalizer/normalizer_class.h
index 4d3f7d2341..3ce37fae88 100644
--- a/ext/intl/normalizer/normalizer_class.h
+++ b/ext/intl/normalizer/normalizer_class.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/normalizer/normalizer_normalize.h b/ext/intl/normalizer/normalizer_normalize.h
index 41c31f7949..c282c56795 100644
--- a/ext/intl/normalizer/normalizer_normalize.h
+++ b/ext/intl/normalizer/normalizer_normalize.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/php_intl.c b/ext/intl/php_intl.c
index 9ca225ab88..2c5e74809d 100644
--- a/ext/intl/php_intl.c
+++ b/ext/intl/php_intl.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/php_intl.h b/ext/intl/php_intl.h
index 86a75cb335..3625c4fdcc 100644
--- a/ext/intl/php_intl.h
+++ b/ext/intl/php_intl.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/resourcebundle/resourcebundle.c b/ext/intl/resourcebundle/resourcebundle.c
index 1232a42868..9b6b734ed6 100644
--- a/ext/intl/resourcebundle/resourcebundle.c
+++ b/ext/intl/resourcebundle/resourcebundle.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/resourcebundle/resourcebundle.h b/ext/intl/resourcebundle/resourcebundle.h
index 607ece98ba..e5aa9f092b 100644
--- a/ext/intl/resourcebundle/resourcebundle.h
+++ b/ext/intl/resourcebundle/resourcebundle.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/resourcebundle/resourcebundle_class.c b/ext/intl/resourcebundle/resourcebundle_class.c
index a8252de638..0fbf7931d4 100644
--- a/ext/intl/resourcebundle/resourcebundle_class.c
+++ b/ext/intl/resourcebundle/resourcebundle_class.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/resourcebundle/resourcebundle_class.h b/ext/intl/resourcebundle/resourcebundle_class.h
index 7cb015a8df..403b6beb17 100644
--- a/ext/intl/resourcebundle/resourcebundle_class.h
+++ b/ext/intl/resourcebundle/resourcebundle_class.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/resourcebundle/resourcebundle_iterator.c b/ext/intl/resourcebundle/resourcebundle_iterator.c
index bdedfd15bc..cf38c6b676 100644
--- a/ext/intl/resourcebundle/resourcebundle_iterator.c
+++ b/ext/intl/resourcebundle/resourcebundle_iterator.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/resourcebundle/resourcebundle_iterator.h b/ext/intl/resourcebundle/resourcebundle_iterator.h
index 32818f847f..b28fa91638 100644
--- a/ext/intl/resourcebundle/resourcebundle_iterator.h
+++ b/ext/intl/resourcebundle/resourcebundle_iterator.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/spoofchecker/spoofchecker.c b/ext/intl/spoofchecker/spoofchecker.c
index 42a014a90e..0a22875dcf 100644
--- a/ext/intl/spoofchecker/spoofchecker.c
+++ b/ext/intl/spoofchecker/spoofchecker.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/spoofchecker/spoofchecker.h b/ext/intl/spoofchecker/spoofchecker.h
index f976d639ac..1cbdd7ea65 100644
--- a/ext/intl/spoofchecker/spoofchecker.h
+++ b/ext/intl/spoofchecker/spoofchecker.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/spoofchecker/spoofchecker_class.c b/ext/intl/spoofchecker/spoofchecker_class.c
index 7ae1a2feb6..5fb6ffb90c 100644
--- a/ext/intl/spoofchecker/spoofchecker_class.c
+++ b/ext/intl/spoofchecker/spoofchecker_class.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/spoofchecker/spoofchecker_class.h b/ext/intl/spoofchecker/spoofchecker_class.h
index 9683b03b08..847b0a97b5 100644
--- a/ext/intl/spoofchecker/spoofchecker_class.h
+++ b/ext/intl/spoofchecker/spoofchecker_class.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/spoofchecker/spoofchecker_create.c b/ext/intl/spoofchecker/spoofchecker_create.c
index cf0173f997..962e31cb08 100644
--- a/ext/intl/spoofchecker/spoofchecker_create.c
+++ b/ext/intl/spoofchecker/spoofchecker_create.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/spoofchecker/spoofchecker_create.h b/ext/intl/spoofchecker/spoofchecker_create.h
index 313faab8a3..405c1bda12 100644
--- a/ext/intl/spoofchecker/spoofchecker_create.h
+++ b/ext/intl/spoofchecker/spoofchecker_create.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/spoofchecker/spoofchecker_main.c b/ext/intl/spoofchecker/spoofchecker_main.c
index e5d11a899e..959a0c568f 100644
--- a/ext/intl/spoofchecker/spoofchecker_main.c
+++ b/ext/intl/spoofchecker/spoofchecker_main.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/spoofchecker/spoofchecker_main.h b/ext/intl/spoofchecker/spoofchecker_main.h
index fb920d7841..44c99ec856 100644
--- a/ext/intl/spoofchecker/spoofchecker_main.h
+++ b/ext/intl/spoofchecker/spoofchecker_main.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/timezone/timezone_class.cpp b/ext/intl/timezone/timezone_class.cpp
index 623a643c49..d2aaa12344 100644
--- a/ext/intl/timezone/timezone_class.cpp
+++ b/ext/intl/timezone/timezone_class.cpp
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/timezone/timezone_class.h b/ext/intl/timezone/timezone_class.h
index 71de20c09e..94b781b332 100644
--- a/ext/intl/timezone/timezone_class.h
+++ b/ext/intl/timezone/timezone_class.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/timezone/timezone_methods.cpp b/ext/intl/timezone/timezone_methods.cpp
index 530e6c5bed..033b216cdf 100644
--- a/ext/intl/timezone/timezone_methods.cpp
+++ b/ext/intl/timezone/timezone_methods.cpp
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/timezone/timezone_methods.h b/ext/intl/timezone/timezone_methods.h
index 28c39f4fd7..29d72913fd 100644
--- a/ext/intl/timezone/timezone_methods.h
+++ b/ext/intl/timezone/timezone_methods.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/transliterator/transliterator.c b/ext/intl/transliterator/transliterator.c
index 5f698e2b90..fda183b85a 100644
--- a/ext/intl/transliterator/transliterator.c
+++ b/ext/intl/transliterator/transliterator.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/transliterator/transliterator.h b/ext/intl/transliterator/transliterator.h
index cfd5d38dbd..081a730cbc 100644
--- a/ext/intl/transliterator/transliterator.h
+++ b/ext/intl/transliterator/transliterator.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
@@ -21,7 +21,7 @@
#include <unicode/utypes.h>
#include <unicode/utrans.h>
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
void transliterator_register_constants( INIT_FUNC_ARGS );
smart_str transliterator_parse_error_to_string( UParseError* pe );
diff --git a/ext/intl/transliterator/transliterator_class.c b/ext/intl/transliterator/transliterator_class.c
index ff299a8f38..647ece8ba0 100644
--- a/ext/intl/transliterator/transliterator_class.c
+++ b/ext/intl/transliterator/transliterator_class.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/transliterator/transliterator_class.h b/ext/intl/transliterator/transliterator_class.h
index a99c2ced16..f70e86995f 100644
--- a/ext/intl/transliterator/transliterator_class.h
+++ b/ext/intl/transliterator/transliterator_class.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/transliterator/transliterator_methods.c b/ext/intl/transliterator/transliterator_methods.c
index 978c830da7..e79aeb1621 100644
--- a/ext/intl/transliterator/transliterator_methods.c
+++ b/ext/intl/transliterator/transliterator_methods.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/intl/transliterator/transliterator_methods.h b/ext/intl/transliterator/transliterator_methods.h
index b806de84fb..ff0b93a29a 100644
--- a/ext/intl/transliterator/transliterator_methods.h
+++ b/ext/intl/transliterator/transliterator_methods.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
diff --git a/ext/json/JSON_parser.h b/ext/json/JSON_parser.h
index 3df999c5f3..da47f4078f 100644
--- a/ext/json/JSON_parser.h
+++ b/ext/json/JSON_parser.h
@@ -4,8 +4,8 @@
#define JSON_PARSER_H
#include "php.h"
-#include "ext/standard/php_smart_str.h"
#include "php_json.h"
+#include "zend_smart_str.h"
#define JSON_PARSER_DEFAULT_DEPTH 512
diff --git a/ext/json/json.c b/ext/json/json.c
index 24324bbe99..16e452a004 100644
--- a/ext/json/json.c
+++ b/ext/json/json.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -26,7 +26,7 @@
#include "php_ini.h"
#include "ext/standard/info.h"
#include "ext/standard/html.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#include "JSON_parser.h"
#include "php_json.h"
#include <zend_exceptions.h>
@@ -384,7 +384,7 @@ static void json_escape_string(smart_str *buf, char *s, size_t len, int options
{
int status;
unsigned int us, next_us = 0;
- size_t pos, checkpoint, newlen;
+ size_t pos, checkpoint;
if (len == 0) {
smart_str_appendl(buf, "\"\"", 2);
@@ -789,7 +789,7 @@ static PHP_FUNCTION(json_encode)
ZVAL_FALSE(return_value);
} else {
smart_str_0(&buf); /* copy? */
- ZVAL_STR(return_value, buf.s);
+ ZVAL_NEW_STR(return_value, buf.s);
}
}
/* }}} */
diff --git a/ext/json/json.dsp b/ext/json/json.dsp
deleted file mode 100644
index e5bb3767bf..0000000000
--- a/ext/json/json.dsp
+++ /dev/null
@@ -1,135 +0,0 @@
-# Microsoft Developer Studio Project File - Name="json" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=json - Win32 Debug_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "json.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "json.mak" CFG="json - Win32 Debug_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "json - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "json - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "json - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "JSON_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /I "json_c" /D HAVE_JSON=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D ZEND_DEBUG=1 /D ZTS=1 /D COMPILE_DL_JSON=1 /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "JSON_EXPORTS" /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x1009 /d "_DEBUG"
-# ADD RSC /l 0x1009 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 iconv.lib php4ts_debug.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_json.dll" /pdbtype:sept /libpath:"..\..\Debug_TS"
-
-!ELSEIF "$(CFG)" == "json - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "JSON_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /I "json_c" /D HAVE_JSON=1 /D "ZEND_WIN32" /D ZEND_DEBUG=0 /D "PHP_WIN32" /D ZTS=1 /D COMPILE_DL_JSON=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "JSON_EXPORTS" /D "HAVE_FCNTL_H" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x1009 /d "NDEBUG"
-# ADD RSC /l 0x1009 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 iconv.lib php4ts.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_json.dll" /libpath:"..\..\Release_TS"
-
-!ENDIF
-
-# Begin Target
-
-# Name "json - Win32 Debug_TS"
-# Name "json - Win32 Release_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=".\json.c"
-# End Source File
-# Begin Source File
-
-SOURCE=.\JSON_parser.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\JSON_parser.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\utf8_decode.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\utf8_decode.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\utf8_to_utf16.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\utf8_to_utf16.h
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_json.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# End Target
-# End Project
diff --git a/ext/json/php_json.h b/ext/json/php_json.h
index 08a4a7ff94..5b2dc127dd 100644
--- a/ext/json/php_json.h
+++ b/ext/json/php_json.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -22,7 +22,7 @@
#define PHP_JSON_H
#define PHP_JSON_VERSION "1.2.1"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str_public.h"
extern zend_module_entry json_module_entry;
#define phpext_json_ptr &json_module_entry
diff --git a/ext/json/utf8_decode.h b/ext/json/utf8_decode.h
index cc0fc79f6c..0908edd2d4 100644
--- a/ext/json/utf8_decode.h
+++ b/ext/json/utf8_decode.h
@@ -5,8 +5,8 @@
typedef struct json_utf8_decode
{
- int the_index;
char *the_input;
+ int the_index;
int the_length;
int the_char;
int the_byte;
diff --git a/ext/ldap/LDAP_Win32_HOWTO.txt b/ext/ldap/LDAP_Win32_HOWTO.txt
index bcee731e88..30b6096f58 100644
--- a/ext/ldap/LDAP_Win32_HOWTO.txt
+++ b/ext/ldap/LDAP_Win32_HOWTO.txt
@@ -14,7 +14,7 @@ Note 1: During the entire build process, you can ignore warnings about
For 'Win32 Debug', change the runtime library to 'Debug Multithreaded DLL'
For 'Win32 Release', change the runtime library to 'Multithreaded DLL'
Select the Preprocessor tab, select 'All Configurations'.
- Add '..\..\..\..\php5\regex' to the 'Additional include directories' list.
+ Add '..\..\..\..\php7\regex' to the 'Additional include directories' list.
Add 'HAVE_MKTEMP' to the 'Preprocessor definitions' list.
- Compile (you can compile both Debug and Release versions).
diff --git a/ext/ldap/ldap.c b/ext/ldap/ldap.c
index 151b059026..f74de699ee 100644
--- a/ext/ldap/ldap.c
+++ b/ext/ldap/ldap.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -388,6 +388,23 @@ static int _get_lderrno(LDAP *ldap)
}
/* }}} */
+/* {{{ _set_lderrno
+ */
+static void _set_lderrno(LDAP *ldap, int lderr)
+{
+#if !HAVE_NSLDAP
+#if LDAP_API_VERSION > 2000 || HAVE_ORALDAP
+ /* New versions of OpenLDAP do it this way */
+ ldap_set_option(ldap, LDAP_OPT_ERROR_NUMBER, &lderr);
+#else
+ ldap->ld_errno = lderr;
+#endif
+#else
+ ldap_set_lderrno(ldap, lderr, NULL, NULL);
+#endif
+}
+/* }}} */
+
/* {{{ proto bool ldap_bind(resource link [, string dn [, string password]])
Bind to LDAP directory */
PHP_FUNCTION(ldap_bind)
@@ -402,18 +419,20 @@ PHP_FUNCTION(ldap_bind)
RETURN_FALSE;
}
+ ZEND_FETCH_RESOURCE(ld, ldap_linkdata *, link, -1, "ldap link", le_link);
+
if (ldap_bind_dn != NULL && memchr(ldap_bind_dn, '\0', ldap_bind_dnlen) != NULL) {
+ _set_lderrno(ld->link, LDAP_INVALID_CREDENTIALS);
php_error_docref(NULL TSRMLS_CC, E_WARNING, "DN contains a null byte");
RETURN_FALSE;
}
if (ldap_bind_pw != NULL && memchr(ldap_bind_pw, '\0', ldap_bind_pwlen) != NULL) {
+ _set_lderrno(ld->link, LDAP_INVALID_CREDENTIALS);
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Password contains a null byte");
RETURN_FALSE;
}
- ZEND_FETCH_RESOURCE(ld, ldap_linkdata *, link, -1, "ldap link", le_link);
-
if ((rc = ldap_bind_s(ld->link, ldap_bind_dn, ldap_bind_pw, LDAP_AUTH_SIMPLE)) != LDAP_SUCCESS) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to bind to server: %s", ldap_err2string(rc));
RETURN_FALSE;
diff --git a/ext/ldap/ldap.dsp b/ext/ldap/ldap.dsp
deleted file mode 100644
index a97ebe4105..0000000000
--- a/ext/ldap/ldap.dsp
+++ /dev/null
@@ -1,288 +0,0 @@
-# Microsoft Developer Studio Project File - Name="ldap" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=ldap - Win32 Debug_TS_SSL
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "ldap.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "ldap.mak" CFG="ldap - Win32 Debug_TS_SSL"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "ldap - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "ldap - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "ldap - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "ldap - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "ldap - Win32 Release_TS SASL" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "ldap - Win32 Debug_TS SASL" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "ldap - Win32 Release_TS_SSL" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "ldap - Win32 Debug_TS_SSL" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "ldap - Win32 Release"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release"
-# PROP BASE Intermediate_Dir "Release"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release"
-# PROP Intermediate_Dir "Release"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LDAP_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\php_build\openldap\include" /D "NDEBUG" /D ZEND_DEBUG=0 /D "COMPILE_DL_LDAP_LDAP" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LDAP_EXPORTS" /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_LDAP=1 /D "COMPILE_DL_LDAP" /D "HAVE_LDAP_START_TLS_S" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 oldap32.lib olber32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib php5nts.lib /nologo /dll /machine:I386 /out:"Release/php_ldap.dll" /libpath:"..\..\Release" /libpath:"..\..\..\php_build\openldap\libraries\Release"
-
-!ELSEIF "$(CFG)" == "ldap - Win32 Debug"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug"
-# PROP BASE Intermediate_Dir "Debug"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug"
-# PROP Intermediate_Dir "Debug"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LDAP_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\php_build\openldap\include" /D "_DEBUG" /D ZEND_DEBUG=1 /D "COMPILE_DL_LDAP_LDAP" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LDAP_EXPORTS" /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_LDAP=1 /D "COMPILE_DL_LDAP" /D "HAVE_LDAP_START_TLS_S" /FR /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 oldap32.lib olber32.lib php5nts_debug.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib /nologo /dll /debug /machine:I386 /out:"Debug/php_ldap.dll" /pdbtype:sept /libpath:"..\..\Debug" /libpath:"..\..\..\php_build\openldap\libraries\Debug"
-
-!ELSEIF "$(CFG)" == "ldap - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\openldap\include" /D "_DEBUG" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LDAP_EXPORTS" /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_LDAP=1 /D ZEND_DEBUG=1 /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\php_build\openldap\include" /D "_DEBUG" /D ZEND_DEBUG=1 /D "ZTS" /D "COMPILE_DL_LDAP" /D "HAVE_LDAP_START_TLS_S" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LDAP_EXPORTS" /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_LDAP=1 /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 oldap32.lib olber32.lib php5nts_debug.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept /libpath:"..\..\..\openldap\libraries\Debug" /libpath:"..\..\Debug"
-# ADD LINK32 oldap32.lib olber32.lib php5ts_debug.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_ldap.dll" /pdbtype:sept /libpath:"..\..\Debug_TS" /libpath:"..\..\..\php_build\openldap\libraries\Debug"
-
-!ELSEIF "$(CFG)" == "ldap - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\openldap\include" /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LDAP_EXPORTS" /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_LDAP=1 /D ZEND_DEBUG=0 /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\php_build\openldap\include" /D "NDEBUG" /D ZEND_DEBUG=0 /D "ZTS" /D "COMPILE_DL_LDAP" /D "HAVE_LDAP_START_TLS_S" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LDAP_EXPORTS" /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_LDAP=1 /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 oldap32.lib olber32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib php5ts.lib /nologo /dll /machine:I386
-# ADD LINK32 oldap32.lib olber32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib php5ts.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_ldap.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\..\php_build\openldap\libraries\Release" /libpath:"..\..\Release_TS_Inline"
-
-!ELSEIF "$(CFG)" == "ldap - Win32 Release_TS SASL"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "ldap___Win32_Release_TS_SASL"
-# PROP BASE Intermediate_Dir "ldap___Win32_Release_TS_SASL"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS_SASL"
-# PROP Intermediate_Dir "Release_TS_SASL"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\php_build\openldap\include" /D "NDEBUG" /D ZEND_DEBUG=0 /D "ZTS" /D "COMPILE_DL_LDAP" /D "HAVE_LDAP_START_TLS_S" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LDAP_EXPORTS" /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_LDAP=1 /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\php_build\openldap\include" /D "NDEBUG" /D ZEND_DEBUG=0 /D "ZTS" /D "COMPILE_DL_LDAP" /D "HAVE_LDAP_START_TLS_S" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LDAP_EXPORTS" /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_LDAP=1 /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 oldap32.lib olber32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib php5ts.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_ldap.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\..\php_build\openldap\libraries\Release" /libpath:"..\..\Release_TS_Inline"
-# ADD LINK32 oldap32.lib olber32.lib libsasl.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib php5ts.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_ldap.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\..\php_build\openldap\libraries\Release" /libpath:"..\..\Release_TS_Inline"
-
-!ELSEIF "$(CFG)" == "ldap - Win32 Debug_TS SASL"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "ldap___Win32_Debug_TS_SASL"
-# PROP BASE Intermediate_Dir "ldap___Win32_Debug_TS_SASL"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS_SASL"
-# PROP Intermediate_Dir "Debug_TS_SASL"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\php_build\openldap\include" /D "_DEBUG" /D ZEND_DEBUG=1 /D "ZTS" /D "COMPILE_DL_LDAP" /D "HAVE_LDAP_START_TLS_S" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LDAP_EXPORTS" /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_LDAP=1 /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\php_build\openldap\include" /D "_DEBUG" /D ZEND_DEBUG=1 /D "ZTS" /D "COMPILE_DL_LDAP" /D "HAVE_LDAP_START_TLS_S" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LDAP_EXPORTS" /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_LDAP=1 /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 oldap32.lib olber32.lib php5ts_debug.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib /nologo /dll /debug /machine:I386 /out:"Debug_TS/php_ldap.dll" /pdbtype:sept /libpath:"..\..\Debug_TS" /libpath:"..\..\..\php_build\openldap\libraries\Debug"
-# ADD LINK32 oldap32.lib olber32.lib libsasl.lib php5ts_debug.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_ldap.dll" /pdbtype:sept /libpath:"..\..\Debug_TS" /libpath:"..\..\..\php_build\openldap\libraries\Debug"
-
-!ELSEIF "$(CFG)" == "ldap - Win32 Release_TS_SSL"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "ldap___Win32_Release_TS_SSL"
-# PROP BASE Intermediate_Dir "ldap___Win32_Release_TS_SSL"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS_SSL"
-# PROP Intermediate_Dir "Release_TS_SSL"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\php_build\openldap\include" /D "NDEBUG" /D ZEND_DEBUG=0 /D "ZTS" /D "COMPILE_DL_LDAP" /D "HAVE_LDAP_START_TLS_S" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LDAP_EXPORTS" /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_LDAP=1 /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\php_build\openldap\include" /D "NDEBUG" /D ZEND_DEBUG=0 /D "ZTS" /D "COMPILE_DL_LDAP" /D "HAVE_LDAP_START_TLS_S" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LDAP_EXPORTS" /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_LDAP=1 /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 oldap32.lib olber32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib php5ts.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_ldap.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\..\php_build\openldap\libraries\Release" /libpath:"..\..\Release_TS_Inline"
-# ADD LINK32 php5ts.lib oldap32.lib olber32.lib ssleay32.lib libeay32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_ldap.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\..\php_build\openldap\libraries\Release" /libpath:"..\..\Release_TS_Inline"
-
-!ELSEIF "$(CFG)" == "ldap - Win32 Debug_TS_SSL"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "ldap___Win32_Debug_TS_SSL"
-# PROP BASE Intermediate_Dir "ldap___Win32_Debug_TS_SSL"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS_SSL"
-# PROP Intermediate_Dir "Debug_TS_SSL"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\php_build\openldap\include" /D "_DEBUG" /D ZEND_DEBUG=1 /D "ZTS" /D "COMPILE_DL_LDAP" /D "HAVE_LDAP_START_TLS_S" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LDAP_EXPORTS" /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_LDAP=1 /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\php_build\openldap\include" /D "_DEBUG" /D ZEND_DEBUG=1 /D "ZTS" /D "COMPILE_DL_LDAP" /D "HAVE_LDAP_START_TLS_S" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "LDAP_EXPORTS" /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_LDAP=1 /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 oldap32.lib olber32.lib php5ts_debug.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_ldap.dll" /pdbtype:sept /libpath:"..\..\Debug_TS" /libpath:"..\..\..\php_build\openldap\libraries\Debug"
-# ADD LINK32 php5ts_debug.lib oldap32.lib olber32.lib ssleay32.lib libeay32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib wsock32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_ldap.dll" /pdbtype:sept /libpath:"..\..\Debug_TS" /libpath:"..\..\..\php_build\openldap\libraries\Debug"
-
-!ENDIF
-
-# Begin Target
-
-# Name "ldap - Win32 Release"
-# Name "ldap - Win32 Debug"
-# Name "ldap - Win32 Debug_TS"
-# Name "ldap - Win32 Release_TS"
-# Name "ldap - Win32 Release_TS SASL"
-# Name "ldap - Win32 Debug_TS SASL"
-# Name "ldap - Win32 Release_TS_SSL"
-# Name "ldap - Win32 Debug_TS_SSL"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\ldap.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_ldap.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# Begin Source File
-
-SOURCE=.\LDAP_Win32_HOWTO.txt
-# End Source File
-# End Target
-# End Project
diff --git a/ext/ldap/ldap.mak b/ext/ldap/ldap.mak
index 959fe16cf1..f285db0eff 100644
--- a/ext/ldap/ldap.mak
+++ b/ext/ldap/ldap.mak
@@ -4,7 +4,7 @@ PROJECT_ROOT = ..\..
# Module details
MODULE_NAME = php_ldap
-MODULE_DESC = "PHP 5 - LDAP Extension"
+MODULE_DESC = "PHP 7 - LDAP Extension"
VMAJ = 3
VMIN = 0
VREV = 0
diff --git a/ext/ldap/php_ldap.h b/ext/ldap/php_ldap.h
index 944c3dd531..0ccdbfe665 100644
--- a/ext/ldap/php_ldap.h
+++ b/ext/ldap/php_ldap.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/libxml/libxml.c b/ext/libxml/libxml.c
index 8fd661c81d..d9e92541e9 100644
--- a/ext/libxml/libxml.c
+++ b/ext/libxml/libxml.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -1030,20 +1030,20 @@ static PHP_FUNCTION(libxml_get_errors)
zval z_error;
object_init_ex(&z_error, libxmlerror_class_entry);
- add_property_long(&z_error, "level", error->level);
- add_property_long(&z_error, "code", error->code);
- add_property_long(&z_error, "column", error->int2);
+ add_property_long_ex(&z_error, "level", sizeof("level") - 1, error->level TSRMLS_CC);
+ add_property_long_ex(&z_error, "code", sizeof("code") - 1, error->code TSRMLS_CC);
+ add_property_long_ex(&z_error, "column", sizeof("column") - 1, error->int2 TSRMLS_CC);
if (error->message) {
- add_property_string(&z_error, "message", error->message);
+ add_property_string_ex(&z_error, "message", sizeof("message") - 1, error->message TSRMLS_CC);
} else {
- add_property_stringl(&z_error, "message", "", 0);
+ add_property_stringl_ex(&z_error, "message", sizeof("message") - 1, "", 0 TSRMLS_CC);
}
if (error->file) {
- add_property_string(&z_error, "file", error->file);
+ add_property_string_ex(&z_error, "file", sizeof("file") - 1, error->file TSRMLS_CC);
} else {
- add_property_stringl(&z_error, "file", "", 0);
+ add_property_stringl_ex(&z_error, "file", sizeof("file") - 1, "", 0 TSRMLS_CC);
}
- add_property_long(&z_error, "line", error->line);
+ add_property_long_ex(&z_error, "line", sizeof("line") - 1, error->line TSRMLS_CC);
add_next_index_zval(return_value, &z_error);
error = zend_llist_get_next(LIBXML(error_list));
diff --git a/ext/libxml/php_libxml.h b/ext/libxml/php_libxml.h
index b79ca17556..cccc83f8db 100644
--- a/ext/libxml/php_libxml.h
+++ b/ext/libxml/php_libxml.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -34,7 +34,7 @@ extern zend_module_entry libxml_module_entry;
# define PHP_LIBXML_API
#endif
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#include <libxml/tree.h>
#define LIBXML_SAVE_NOEMPTYTAG 1<<2
diff --git a/ext/mbstring/libmbfl/NEWS b/ext/mbstring/libmbfl/NEWS
index fc16367ed1..8217e4158f 100644
--- a/ext/mbstring/libmbfl/NEWS
+++ b/ext/mbstring/libmbfl/NEWS
@@ -27,4 +27,3 @@ version 1.1.0 March 02, 2010
- added cp5022x encoding (moriyoshi)
- added ISO-2022-JP-MS (moriyoshi)
- moved to github.com from sourceforge.jp (moriyoshi)
-
diff --git a/ext/mbstring/mb_gpc.c b/ext/mbstring/mb_gpc.c
index 92e7327787..a50768f6d0 100644
--- a/ext/mbstring/mb_gpc.c
+++ b/ext/mbstring/mb_gpc.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mbstring/mb_gpc.h b/ext/mbstring/mb_gpc.h
index ab6fcc86e0..091d8e2d9b 100644
--- a/ext/mbstring/mb_gpc.h
+++ b/ext/mbstring/mb_gpc.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2001 The PHP Group |
+----------------------------------------------------------------------+
@@ -30,14 +30,14 @@
#if HAVE_MBSTRING
/* {{{ typedefs */
typedef struct _php_mb_encoding_handler_info_t {
- int data_type;
const char *separator;
- unsigned int report_errors: 1;
- enum mbfl_no_language to_language;
const mbfl_encoding *to_encoding;
- enum mbfl_no_language from_language;
const mbfl_encoding **from_encodings;
size_t num_from_encodings;
+ int data_type;
+ unsigned int report_errors : 1;
+ enum mbfl_no_language to_language;
+ enum mbfl_no_language from_language;
} php_mb_encoding_handler_info_t;
/* }}}*/
diff --git a/ext/mbstring/mbstring.c b/ext/mbstring/mbstring.c
index 212c8d013f..691391ab92 100644
--- a/ext/mbstring/mbstring.c
+++ b/ext/mbstring/mbstring.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -2963,7 +2963,7 @@ PHP_FUNCTION(mb_strimwidth)
string.val = (unsigned char *)str;
string.len = str_len;
- if (from < 0 || from > str_len) {
+ if (from < 0 || (size_t)from > str_len) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Start position is out of range");
RETURN_FALSE;
}
@@ -4195,7 +4195,7 @@ PHP_FUNCTION(mb_send_mail)
}
/* Subject: */
- if (subject != NULL && subject_len >= 0) {
+ if (subject != NULL) {
orig_str.no_language = MBSTRG(language);
orig_str.val = (unsigned char *)subject;
orig_str.len = subject_len;
diff --git a/ext/mbstring/mbstring.dsp b/ext/mbstring/mbstring.dsp
deleted file mode 100644
index 2e050c6d20..0000000000
--- a/ext/mbstring/mbstring.dsp
+++ /dev/null
@@ -1,1112 +0,0 @@
-# Microsoft Developer Studio Project File - Name="mbstring" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=mbstring - Win32 Debug_TS MBSTRING
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "mbstring.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "mbstring.mak" CFG="mbstring - Win32 Debug_TS MBSTRING"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "mbstring - Win32 Release_TS MBSTRING" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "mbstring - Win32 Debug_TS MBSTRING" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "mbstring - Win32 Release_TS MBSTRING"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "mbstring___Win32_Release_TS_MBSTRING"
-# PROP BASE Intermediate_Dir "mbstring___Win32_Release_TS_MBSTRING"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /D ZEND_DEBUG=0 /D "_MBCS" /D "_USRDLL" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "COMPILE_DL_MBSTRING" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D MBSTRING_EXPORTS=1 /D HAVE_MBSTRING=1 /D HAVE_MBREGEX=1 /D HAVE_MBSTR_CN=1 /D HAVE_MBSTR_JA=1 /D HAVE_MBSTR_KR=1 /D HAVE_MBSTR_RU=1 /D HAVE_MBSTR_TW=1 /FR /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /I "libmbfl" /I "libmbfl\mbfl" /D ZEND_DEBUG=0 /D "MBSTRING_EXPORTS" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "COMPILE_DL_MBSTRING" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_MBSTRING=1 /D HAVE_MBSTR_CN=1 /D HAVE_MBSTR_JA=1 /D HAVE_MBSTR_KR=1 /D HAVE_MBSTR_RU=1 /D HAVE_MBSTR_TW=1 /D MBFL_DLL_EXPORT=1 /D NOT_RUBY=1 /D "LIBMBFL_EXPORTS" /D "HAVE_STRICMP" /D "HAVE_CONFIG_H" /D "HAVE_STDLIB_H" /FR /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 php5ts.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_mbstring.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-# ADD LINK32 php5ts.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_mbstring.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-
-!ELSEIF "$(CFG)" == "mbstring - Win32 Debug_TS MBSTRING"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "mbstring___Win32_Debug_TS_MBSTRING"
-# PROP BASE Intermediate_Dir "mbstring___Win32_Debug_TS_MBSTRING"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /D ZEND_DEBUG=1 /D "MBSTRING_EXPORTS" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "COMPILE_DL_MBSTRING" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D MBSTRING_EXPORTS=1 /D HAVE_MBSTRING=1 /D HAVE_MBREGEX=1 /D HAVE_MBSTR_CN=1 /D HAVE_MBSTR_JA=1 /D HAVE_MBSTR_KR=1 /D HAVE_MBSTR_RU=1 /D HAVE_MBSTR_TW=1 /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /I "libmbfl" /I "libmbfl\mbfl" /I "oniguruma" /D ZEND_DEBUG=1 /D MBSTRING_EXPORTS=1 /D HAVE_STDLIB_H=1 /D HAVE_STRING_H=1 /D "MBSTRING_EXPORTS" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "COMPILE_DL_MBSTRING" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_MBSTRING=1 /D HAVE_MBSTR_CN=1 /D HAVE_MBSTR_JA=1 /D HAVE_MBSTR_KR=1 /D HAVE_MBSTR_RU=1 /D HAVE_MBSTR_TW=1 /D MBFL_DLL_EXPORT=1 /D NOT_RUBY=1 /D "LIBMBFL_EXPORTS" /D "HAVE_STRICMP" /D "HAVE_CONFIG_H" /D "HAVE_STDLIB_H" /FR /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 php5ts_debug.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_mbstring.dll" /pdbtype:sept /libpath:"..\..\Debug_TS"
-# ADD LINK32 php5ts_debug.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_mbstring.dll" /pdbtype:sept /libpath:"..\..\Debug_TS"
-
-!ENDIF
-
-# Begin Target
-
-# Name "mbstring - Win32 Release_TS MBSTRING"
-# Name "mbstring - Win32 Debug_TS MBSTRING"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\mb_gpc.c
-
-!IF "$(CFG)" == "mbstring - Win32 Release_TS MBSTRING"
-
-# PROP Intermediate_Dir "Release_TS"
-
-!ELSEIF "$(CFG)" == "mbstring - Win32 Debug_TS MBSTRING"
-
-# PROP Intermediate_Dir "Debug_TS"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\mbstring.c
-
-!IF "$(CFG)" == "mbstring - Win32 Release_TS MBSTRING"
-
-# PROP Intermediate_Dir "Release_TS"
-
-!ELSEIF "$(CFG)" == "mbstring - Win32 Debug_TS MBSTRING"
-
-# PROP Intermediate_Dir "Debug_TS"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_mbregex.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_unicode.c
-
-!IF "$(CFG)" == "mbstring - Win32 Release_TS MBSTRING"
-
-# PROP Intermediate_Dir "Release_TS"
-
-!ELSEIF "$(CFG)" == "mbstring - Win32 Debug_TS MBSTRING"
-
-# PROP Intermediate_Dir "Debug_TS"
-
-!ENDIF
-
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\mb_gpc.h
-
-!IF "$(CFG)" == "mbstring - Win32 Release_TS MBSTRING"
-
-# PROP Intermediate_Dir "Release_TS"
-
-!ELSEIF "$(CFG)" == "mbstring - Win32 Debug_TS MBSTRING"
-
-# PROP Intermediate_Dir "Debug_TS"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\mbstring.h
-
-!IF "$(CFG)" == "mbstring - Win32 Release_TS MBSTRING"
-
-# PROP Intermediate_Dir "Release_TS"
-
-!ELSEIF "$(CFG)" == "mbstring - Win32 Debug_TS MBSTRING"
-
-# PROP Intermediate_Dir "Debug_TS"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_mbregex.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_unicode.h
-
-!IF "$(CFG)" == "mbstring - Win32 Release_TS MBSTRING"
-
-# PROP Intermediate_Dir "Release_TS"
-
-!ELSEIF "$(CFG)" == "mbstring - Win32 Debug_TS MBSTRING"
-
-# PROP Intermediate_Dir "Debug_TS"
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\unicode_data.h
-
-!IF "$(CFG)" == "mbstring - Win32 Release_TS MBSTRING"
-
-# PROP Intermediate_Dir "Release_TS"
-
-!ELSEIF "$(CFG)" == "mbstring - Win32 Debug_TS MBSTRING"
-
-# PROP Intermediate_Dir "Debug_TS"
-
-!ENDIF
-
-# End Source File
-# End Group
-# Begin Group "libmbfl"
-
-# PROP Default_Filter ""
-# Begin Group "Source Files No. 1"
-
-# PROP Default_Filter ""
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\html_entities.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfilter.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_7bit.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfilter_8bit.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_ascii.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_base64.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_big5.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_byte2.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_byte4.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_cp1251.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_cp1252.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_cp866.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_cp932.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_cp936.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_euc_cn.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_euc_jp.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_euc_jp_win.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_euc_kr.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_euc_tw.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_htmlent.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_hz.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso2022_kr.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_1.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_10.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_13.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_14.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_15.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_2.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_3.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_4.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_5.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_6.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_7.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_8.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_9.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_jis.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_koi8r.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_koi8u.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_armscii8.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_cp850.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfilter_pass.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_qprint.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_sjis.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_ucs2.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_ucs4.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_uhc.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_utf16.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_utf32.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_utf7.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_utf7imap.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_utf8.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_uuencode.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfilter_wchar.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfl_allocators.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfl_convert.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfl_encoding.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfl_filter_output.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfl_ident.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfl_language.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfl_memory_device.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfl_string.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\nls\nls_de.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\nls\nls_en.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\nls\nls_ja.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\nls\nls_kr.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\nls\nls_neutral.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\nls\nls_ru.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\nls\nls_uni.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\nls\nls_zh.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\nls\nls_hy.c
-# End Source File
-# End Group
-# Begin Group "Header Files No. 1"
-
-# PROP Default_Filter ""
-# Begin Source File
-
-SOURCE=.\libmbfl\config.h.vc6
-
-!IF "$(CFG)" == "mbstring - Win32 Release_TS MBSTRING"
-
-# Begin Custom Build
-InputDir=.\libmbfl
-InputPath=.\libmbfl\config.h.vc6
-
-"$(InputDir)\config.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- copy $(InputDir)\config.h.vc6 "$(InputDir)\config.h"
-
-# End Custom Build
-
-!ELSEIF "$(CFG)" == "mbstring - Win32 Debug_TS MBSTRING"
-
-# Begin Custom Build
-InputDir=.\libmbfl
-InputPath=.\libmbfl\config.h.vc6
-
-"$(InputDir)\config.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- copy $(InputDir)\config.h.vc6 "$(InputDir)\config.h"
-
-# End Custom Build
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\cp932_table.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\html_entities.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfilter.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_7bit.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfilter_8bit.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_ascii.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_base64.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_big5.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_byte2.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_byte4.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_cp1251.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_cp1252.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_cp866.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_cp932.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_cp936.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_euc_cn.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_euc_jp.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_euc_jp_win.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_euc_kr.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_euc_tw.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_htmlent.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_hz.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso2022_kr.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_1.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_10.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_13.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_14.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_15.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_2.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_3.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_4.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_5.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_6.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_7.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_8.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_iso8859_9.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_jis.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_koi8r.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_koi8u.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_armscii8.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_cp850.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfilter_pass.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_qprint.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_sjis.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_ucs2.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_ucs4.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_uhc.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_utf16.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_utf32.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_utf7.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_utf7imap.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_utf8.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\mbfilter_uuencode.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfilter_wchar.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfl_allocators.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfl_consts.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfl_convert.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfl_defs.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfl_encoding.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfl_filter_output.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfl_ident.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfl_language.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfl_memory_device.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\mbfl\mbfl_string.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\nls\nls_de.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\nls\nls_en.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\nls\nls_ja.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\nls\nls_kr.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\nls\nls_neutral.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\nls\nls_ru.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\nls\nls_uni.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\nls\nls_zh.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\nls\nls_hy.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_prop.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_big5.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_cns11643.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_cp1251.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_cp1252.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_cp866.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_cp932_ext.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_cp936.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_iso8859_10.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_iso8859_13.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_iso8859_14.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_iso8859_15.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_iso8859_2.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_iso8859_3.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_iso8859_4.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_iso8859_5.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_iso8859_6.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_iso8859_7.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_iso8859_8.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_iso8859_9.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_jis.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_koi8r.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_koi8u.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_armscii8.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_cp850.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libmbfl\filters\unicode_table_uhc.h
-# End Source File
-# End Group
-# End Group
-# Begin Group "oniguruma"
-
-# PROP Default_Filter ""
-# Begin Group "Source Files No. 2"
-
-# PROP Default_Filter ""
-# Begin Source File
-
-SOURCE=.\oniguruma\regcomp.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\regerror.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\regexec.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\reggnu.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\regparse.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\regposerr.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\ascii.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\utf8.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\euc_jp.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\euc_tw.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\euc_kr.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\sjis.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\iso8859_1.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\iso8859_2.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\iso8859_3.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\iso8859_4.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\iso8859_5.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\iso8859_6.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\iso8859_7.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\iso8859_8.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\iso8859_9.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\iso8859_10.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\iso8859_11.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\iso8859_13.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\iso8859_14.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\iso8859_15.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\iso8859_16.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\koi8.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\koi8_r.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\enc\big5.c
-# End Source File
-# End Group
-# Begin Group "Header Files No. 2"
-
-# PROP Default_Filter ""
-# Begin Source File
-
-SOURCE=.\oniguruma\win32\config.h
-
-!IF "$(CFG)" == "mbstring - Win32 Release_TS MBSTRING"
-
-# Begin Custom Build
-InputDir=.\oniguruma\win32
-InputPath=.\oniguruma\win32\config.h
-
-"$(InputDir)\..\config.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- copy $(InputDir)\config.h "$(InputDir)\..\config.h"
-
-# End Custom Build
-
-!ELSEIF "$(CFG)" == "mbstring - Win32 Debug_TS MBSTRING"
-
-# Begin Custom Build
-InputDir=.\oniguruma\win32
-InputPath=.\oniguruma\win32\config.h
-
-"$(InputDir)\..\config.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
- copy $(InputDir)\config.h "$(InputDir)\..\config.h"
-
-# End Custom Build
-
-!ENDIF
-
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\onigposix.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\oniguruma.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\php_compat.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\regint.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\oniguruma\regparse.h
-# End Source File
-# End Group
-# End Group
-# End Target
-# End Project
diff --git a/ext/mbstring/mbstring.h b/ext/mbstring/mbstring.h
index 8e6310f75f..0136f8ef7d 100644
--- a/ext/mbstring/mbstring.h
+++ b/ext/mbstring/mbstring.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mbstring/php_mbregex.c b/ext/mbstring/php_mbregex.c
index 9628ee2526..de0bc768ad 100644
--- a/ext/mbstring/php_mbregex.c
+++ b/ext/mbstring/php_mbregex.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -28,7 +28,7 @@
#if HAVE_MBREGEX
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#include "ext/standard/info.h"
#include "php_mbregex.h"
#include "mbstring.h"
@@ -717,7 +717,7 @@ static void _php_mb_regex_ereg_exec(INTERNAL_FUNCTION_PARAMETERS, int icase)
/* don't bother doing an extended regex with just a number */
}
- if (!Z_STRVAL_P(arg_pattern) || Z_STRLEN_P(arg_pattern) == 0) {
+ if (Z_STRLEN_P(arg_pattern) == 0) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "empty pattern");
RETVAL_FALSE;
goto out;
@@ -1081,7 +1081,7 @@ PHP_FUNCTION(mb_split)
err = 0;
regs = onig_region_new();
/* churn through str, generating array entries as we go */
- while (count != 0 && (pos - (OnigUChar *)string) < string_len) {
+ while (count != 0 && (pos - (OnigUChar *)string) < (ptrdiff_t)string_len) {
int beg, end;
err = onig_search(re, (OnigUChar *)string, (OnigUChar *)(string + string_len), pos, (OnigUChar *)(string + string_len), regs, 0);
if (err < 0) {
@@ -1403,7 +1403,7 @@ PHP_FUNCTION(mb_ereg_search_setpos)
return;
}
- if (position < 0 || (!Z_ISUNDEF(MBREX(search_str)) && Z_TYPE(MBREX(search_str)) == IS_STRING && position >= Z_STRLEN(MBREX(search_str)))) {
+ if (position < 0 || (!Z_ISUNDEF(MBREX(search_str)) && Z_TYPE(MBREX(search_str)) == IS_STRING && (size_t)position >= Z_STRLEN(MBREX(search_str)))) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Position is out of range");
MBREX(search_pos) = 0;
RETURN_FALSE;
diff --git a/ext/mbstring/php_mbregex.h b/ext/mbstring/php_mbregex.h
index 3d2e2b8e46..0088b0a716 100644
--- a/ext/mbstring/php_mbregex.h
+++ b/ext/mbstring/php_mbregex.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mbstring/php_unicode.c b/ext/mbstring/php_unicode.c
index a1db6819e9..ee5b75e67a 100644
--- a/ext/mbstring/php_unicode.c
+++ b/ext/mbstring/php_unicode.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mbstring/php_unicode.h b/ext/mbstring/php_unicode.h
index 5932b8d2da..e376895cbd 100644
--- a/ext/mbstring/php_unicode.h
+++ b/ext/mbstring/php_unicode.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mbstring/tests/zend_multibyte-02.phpt b/ext/mbstring/tests/zend_multibyte-02.phpt
index 8a1a572804..7db444841e 100644
--- a/ext/mbstring/tests/zend_multibyte-02.phpt
+++ b/ext/mbstring/tests/zend_multibyte-02.phpt
@@ -1,6 +1,7 @@
--TEST--
zend multibyte (2)
--INI--
+error_reporting=E_ALL & ~E_DEPRECATED
zend.multibyte=On
zend.script_encoding=UTF-8
mbstring.internal_encoding=CP932
@@ -9,4 +10,4 @@ mbstring.internal_encoding=CP932
var_dump(bin2hex("テスト"));
?>
--EXPECTF--
-php: Zend/zend_language_scanner.l:%d: encoding_filter_script_to_internal: Assertion `internal_encoding && zend_multibyte_check_lexer_compatibility(internal_encoding)' failed.
+string(12) "836583588367"
diff --git a/ext/mbstring/tests/zend_multibyte-06.phpt b/ext/mbstring/tests/zend_multibyte-06.phpt
index 1b8adb5186..7eeac1d353 100644
--- a/ext/mbstring/tests/zend_multibyte-06.phpt
+++ b/ext/mbstring/tests/zend_multibyte-06.phpt
@@ -10,4 +10,4 @@ declare(encoding="UTF-8");
var_dump(bin2hex("テスト"));
?>
--EXPECTF--
-php: Zend/zend_language_scanner.l:%d: encoding_filter_script_to_internal: Assertion `internal_encoding && zend_multibyte_check_lexer_compatibility(internal_encoding)' failed.
+string(12) "836583588367"
diff --git a/ext/mbstring/tests/zend_multibyte-07.phpt b/ext/mbstring/tests/zend_multibyte-07.phpt
index 50d4cd95ed..685c6f1f04 100644
--- a/ext/mbstring/tests/zend_multibyte-07.phpt
+++ b/ext/mbstring/tests/zend_multibyte-07.phpt
@@ -1,8 +1,5 @@
--TEST--
zend multibyte (7)
---SKIPIF--
---XFAIL--
-https://bugs.php.net/bug.php?id=66582
--INI--
error_reporting=E_ALL & ~E_DEPRECATED
zend.multibyte=On
diff --git a/ext/mbstring/tests/zend_multibyte-09.phpt b/ext/mbstring/tests/zend_multibyte-09.phpt
index 7b0015c6c1..f9b8bf734f 100644
--- a/ext/mbstring/tests/zend_multibyte-09.phpt
+++ b/ext/mbstring/tests/zend_multibyte-09.phpt
@@ -1,8 +1,5 @@
--TEST--
zend multibyte (9)
---SKIPIF--
---XFAIL--
-https://bugs.php.net/bug.php?id=66582
--INI--
error_reporting=E_ALL & ~E_DEPRECATED
zend.multibyte=On
diff --git a/ext/mcrypt/mcrypt.c b/ext/mcrypt/mcrypt.c
index bfd9003e55..82cbe72176 100644
--- a/ext/mcrypt/mcrypt.c
+++ b/ext/mcrypt/mcrypt.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -40,7 +40,7 @@
#include "php_globals.h"
#include "ext/standard/info.h"
#include "ext/standard/php_rand.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#include "php_mcrypt_filter.h"
static int le_mcrypt;
@@ -452,7 +452,7 @@ static PHP_MSHUTDOWN_FUNCTION(mcrypt) /* {{{ */
}
/* }}} */
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
PHP_MINFO_FUNCTION(mcrypt) /* {{{ */
{
diff --git a/ext/mcrypt/mcrypt.dsp b/ext/mcrypt/mcrypt.dsp
deleted file mode 100644
index a0a1f00f4c..0000000000
--- a/ext/mcrypt/mcrypt.dsp
+++ /dev/null
@@ -1,117 +0,0 @@
-# Microsoft Developer Studio Project File - Name="mcrypt" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=mcrypt - Win32 Release_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "mcrypt.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "mcrypt.mak" CFG="mcrypt - Win32 Release_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "mcrypt - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "mcrypt - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "mcrypt - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\TSRM" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MSSQL_EXPORTS" /D "COMPILE_DL_MCRYPT" /D "DBNTWIN32" /D ZTS=1 /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\php_build\mcrypt\include" /D ZEND_DEBUG=0 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MCRYPT_EXPORTS" /D "COMPILE_DL_MCRYPT" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_LIBMCRYPT=1 /D HAVE_LIBMCRYPT24=1 /D HAVE_MCRYPT_GENERIC_DEINIT /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib ntwdblib.lib /nologo /dll /machine:I386 /out:"MSSQL_65_Release/php_mssql.dll" /libpath:"..\..\Release_TS"
-# ADD LINK32 php5ts.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib libmcrypt.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_mcrypt.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\..\php_build\mcrypt" /libpath:"..\..\Release_TS_Inline" /libpath:"..\..\TSRM\Release_TS" /libpath:"..\..\TSRM\Release_TS_Inline"
-
-!ELSEIF "$(CFG)" == "mcrypt - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "mssql-70" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MSSQL_EXPORTS" /D "COMPILE_DL_MCRYPT" /D "DBNTWIN32" /D ZTS=1 /D MSSQL70=1 /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\php_build\mcrypt\include" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MCRYPT_EXPORTS" /D "COMPILE_DL_MCRYPT" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_LIBMCRYPT=1 /D HAVE_LIBMCRYPT24=1 /D HAVE_MCRYPT_GENERIC_DEINIT /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib ntwdblib.lib /nologo /dll /machine:I386 /out:"MSSQL_65_Release/php_mssql.dll" /libpath:"..\..\Release_TS" /libpath:"mssql-70"
-# ADD LINK32 php5ts_debug.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib libmcrypt.lib /nologo /dll /machine:I386 /out:"..\..\Debug_TS/php_mcrypt.dll" /libpath:"..\..\Debug_TS" /libpath:"..\..\..\php_build\mcrypt\lib"
-
-!ENDIF
-
-# Begin Target
-
-# Name "mcrypt - Win32 Release_TS"
-# Name "mcrypt - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\mcrypt.c
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\win32\readdir.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_mcrypt.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\win32\readdir.h
-# End Source File
-# End Group
-# End Target
-# End Project
diff --git a/ext/mcrypt/mcrypt_filter.c b/ext/mcrypt/mcrypt_filter.c
index 698664b236..26f3dceba7 100644
--- a/ext/mcrypt/mcrypt_filter.c
+++ b/ext/mcrypt/mcrypt_filter.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mcrypt/php_mcrypt.h b/ext/mcrypt/php_mcrypt.h
index 9dfa1d8185..994e1cbfa5 100644
--- a/ext/mcrypt/php_mcrypt.h
+++ b/ext/mcrypt/php_mcrypt.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mcrypt/php_mcrypt_filter.h b/ext/mcrypt/php_mcrypt_filter.h
index bfb0d7288f..cacac5ca46 100644
--- a/ext/mcrypt/php_mcrypt_filter.h
+++ b/ext/mcrypt/php_mcrypt_filter.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mssql/mssql.dsp b/ext/mssql/mssql.dsp
deleted file mode 100644
index 43294280dd..0000000000
--- a/ext/mssql/mssql.dsp
+++ /dev/null
@@ -1,117 +0,0 @@
-# Microsoft Developer Studio Project File - Name="mssql" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=mssql - Win32 Release_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "mssql.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "mssql.mak" CFG="mssql - Win32 Release_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "mssql - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "mssql - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "mssql - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /D MSSQL70=1 /D ZEND_DEBUG=0 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MSSQL_EXPORTS" /D "COMPILE_DL_MSSQL" /D "DBNTWIN32" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_MSSQL=1 /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /D MSSQL70=1 /D ZEND_DEBUG=0 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MSSQL_EXPORTS" /D "COMPILE_DL_MSSQL" /D "DBNTWIN32" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_MSSQL=1 /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib ntwdblib.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_mssql70.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\..\php_build\mssql-70\lib" /libpath:"..\..\Release_TS_Inline"
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib ntwdblib.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_mssql.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\..\php_build\mssql-70\lib" /libpath:"..\..\Release_TS_Inline"
-
-!ELSEIF "$(CFG)" == "mssql - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MDd /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /D MSSQL70=1 /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MSSQL_EXPORTS" /D "COMPILE_DL_MSSQL" /D "DBNTWIN32" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_MSSQL=1 /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /D MSSQL70=1 /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MSSQL_EXPORTS" /D "COMPILE_DL_MSSQL" /D "DBNTWIN32" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_MSSQL=1 /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts_debug.lib ntwdblib.lib /nologo /dll /machine:I386 /out:"..\..\Debug_TS/php_mssql70.dll" /libpath:"..\..\Debug_TS" /libpath:"..\..\..\php_build\mssql-70\lib"
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts_debug.lib ntwdblib.lib /nologo /dll /incremental:yes /debug /machine:I386 /out:"..\..\Debug_TS/php_mssql.dll" /pdbtype:sept /libpath:"..\..\Debug_TS" /libpath:"..\..\..\php_build\mssql-70\lib"
-
-!ENDIF
-
-# Begin Target
-
-# Name "mssql - Win32 Release_TS"
-# Name "mssql - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\php_mssql.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_mssql.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# Begin Source File
-
-SOURCE=.\mssql_win32_howto.txt
-# End Source File
-# End Target
-# End Project
diff --git a/ext/mssql/mssql_win32_howto.txt b/ext/mssql/mssql_win32_howto.txt
index d42bc2555b..735226f88a 100644
--- a/ext/mssql/mssql_win32_howto.txt
+++ b/ext/mssql/mssql_win32_howto.txt
@@ -12,7 +12,7 @@ Win32 Debug_TS
php_build\mssql-70\include\sqlfront.h
php_build\mssql-70\lib\ntwdblib.lib
-php_build is a directory at the same level as php5.
+php_build is a directory at the same level as php7.
Start Visual Studio, load php_modules.dsw, select the MSSQL projects,
configuration and build it.
diff --git a/ext/mssql/php_mssql.c b/ext/mssql/php_mssql.c
index 4bb7454c43..1ba77ca8c4 100644
--- a/ext/mssql/php_mssql.c
+++ b/ext/mssql/php_mssql.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -489,7 +489,7 @@ PHP_RINIT_FUNCTION(mssql)
{
MS_SQL_G(default_link) = -1;
MS_SQL_G(num_links) = MS_SQL_G(num_persistent);
- MS_SQL_G(appname) = estrndup("PHP 5", 5);
+ MS_SQL_G(appname) = estrndup("PHP 7", 5);
MS_SQL_G(server_message) = NULL;
MS_SQL_G(min_error_severity) = MS_SQL_G(cfg_min_error_severity);
MS_SQL_G(min_message_severity) = MS_SQL_G(cfg_min_message_severity);
diff --git a/ext/mssql/php_mssql.h b/ext/mssql/php_mssql.h
index 5b2456e9bd..b0313a160a 100644
--- a/ext/mssql/php_mssql.h
+++ b/ext/mssql/php_mssql.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysql/mysql.dsp b/ext/mysql/mysql.dsp
deleted file mode 100644
index dfc9c63db5..0000000000
--- a/ext/mysql/mysql.dsp
+++ /dev/null
@@ -1,171 +0,0 @@
-# Microsoft Developer Studio Project File - Name="mysql" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=mysql - Win32 Debug_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "mysql.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "mysql.mak" CFG="mysql - Win32 Debug_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "mysql - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "mysql - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "mysql - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "mysql - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "mysql - Win32 Release"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release"
-# PROP BASE Intermediate_Dir "Release"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release"
-# PROP Intermediate_Dir "Release"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MYSQL_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\MySQL\include" /I "..\..\TSRM" /D "NDEBUG" /D "MYSQL_EXPORTS" /D "COMPILE_DL_MYSQL" /D HAVE_MYSQL=1 /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ZEND_WIN32" /D "PHP_WIN32" /D "COMPILE_DL_MYSQL" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x40d /d "NDEBUG"
-# ADD RSC /l 0x40d /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib libmySQL.lib php5nts.lib /nologo /dll /machine:I386 /out:"Release/php_mysql.dll" /libpath:"..\..\..\MySQL\lib\opt" /libpath:"..\..\Release"
-
-!ELSEIF "$(CFG)" == "mysql - Win32 Debug"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug"
-# PROP BASE Intermediate_Dir "Debug"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug"
-# PROP Intermediate_Dir "Debug"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MYSQL_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\MySQL\include" /I "..\..\TSRM" /D "_DEBUG" /D ZEND_DEBUG=1 /D "MYSQL_EXPORTS" /D "COMPILE_DL_MYSQL" /D HAVE_MYSQL=1 /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ZEND_WIN32" /D "PHP_WIN32" /D "COMPILE_DL_MYSQL" /FR /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x40d /d "_DEBUG"
-# ADD RSC /l 0x40d /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib libmySQL.lib php5nts_debug.lib /nologo /dll /debug /machine:I386 /out:"Debug/php_mysql.dll" /pdbtype:sept /libpath:"..\..\..\MySQL\lib\Debug" /libpath:"..\..\Debug"
-
-!ELSEIF "$(CFG)" == "mysql - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\..\Zend" /I "..\..\..\bindlib_w32" /D "_DEBUG" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MYSQL_EXPORTS" /D "COMPILE_DL_MYSQL" /D HAVE_MYSQL=1 /FR /YX /FD /GZ /c
-# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\MySQL\include" /I "..\..\TSRM" /D "_DEBUG" /D ZEND_DEBUG=1 /D "ZTS" /D "MYSQL_EXPORTS" /D "COMPILE_DL_MYSQL" /D HAVE_MYSQL=1 /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ZEND_WIN32" /D "PHP_WIN32" /D "COMPILE_DL_MYSQL" /FR /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x40d /d "_DEBUG"
-# ADD RSC /l 0x40d /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 php5ts_debug.lib libmySQL.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_mysql.dll" /pdbtype:sept /libpath:"..\..\..\MySQL\lib\Debug" /libpath:"..\..\Debug_TS"
-
-!ELSEIF "$(CFG)" == "mysql - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\..\Zend" /I "..\..\..\bindlib_w32" /D "NDEBUG" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MYSQL_EXPORTS" /D "COMPILE_DL_MYSQL" /D HAVE_MYSQL=1 /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\MySQL\include" /I "..\..\TSRM" /D "NDEBUG" /D ZEND_DEBUG=0 /D "ZTS" /D "MYSQL_EXPORTS" /D "COMPILE_DL_MYSQL" /D HAVE_MYSQL=1 /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ZEND_WIN32" /D "PHP_WIN32" /D "COMPILE_DL_MYSQL" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x40d /d "NDEBUG"
-# ADD RSC /l 0x40d /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib libmySQL.lib php5ts.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_mysql.dll" /libpath:"..\..\..\MySQL\lib\opt" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-
-!ENDIF
-
-# Begin Target
-
-# Name "mysql - Win32 Release"
-# Name "mysql - Win32 Debug"
-# Name "mysql - Win32 Debug_TS"
-# Name "mysql - Win32 Release_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\php_mysql.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_mysql.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# Begin Source File
-
-SOURCE=.\Readme_w32.txt
-# End Source File
-# End Target
-# End Project
diff --git a/ext/mysql/mysql_mysqlnd.h b/ext/mysql/mysql_mysqlnd.h
index 0c4c221b15..29ac9838f2 100644
--- a/ext/mysql/mysql_mysqlnd.h
+++ b/ext/mysql/mysql_mysqlnd.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2009 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysql/php_mysql.c b/ext/mysql/php_mysql.c
index e3535bc769..fc1dac5da7 100644
--- a/ext/mysql/php_mysql.c
+++ b/ext/mysql/php_mysql.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysql/php_mysql.h b/ext/mysql/php_mysql.h
index 0368140580..279aec001d 100644
--- a/ext/mysql/php_mysql.h
+++ b/ext/mysql/php_mysql.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysql/php_mysql_structs.h b/ext/mysql/php_mysql_structs.h
index c39e5b25af..8eb9aa1d29 100644
--- a/ext/mysql/php_mysql_structs.h
+++ b/ext/mysql/php_mysql_structs.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqli/mysqli.c b/ext/mysqli/mysqli.c
index c5124ebc2f..878c8fb946 100644
--- a/ext/mysqli/mysqli.c
+++ b/ext/mysqli/mysqli.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqli/mysqli.dsp b/ext/mysqli/mysqli.dsp
deleted file mode 100755
index a334202187..0000000000
--- a/ext/mysqli/mysqli.dsp
+++ /dev/null
@@ -1,120 +0,0 @@
-# Microsoft Developer Studio Project File - Name="mysqli" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=mysqli - Win32 Debug_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "mysqli.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "mysqli.mak" CFG="mysqli - Win32 Debug_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "mysqli - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "mysqli - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "mysqli - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MD /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MYSQLI_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\..\php_build\include" /I "..\..\..\php_build\include\mysqli" /D ZEND_DEBUG=0 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "COMPILE_DL_MYSQLI" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D "PHP_MYSQLI_EXPORTS" /D "HAVE_ZLIB" /FR /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "NDEBUG"
-# ADD RSC /l 0x407 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 php5ts.lib zlib.lib libmySQL.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_mysqli.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline" /libpath:"..\..\..\php_build\release"
-
-!ELSEIF "$(CFG)" == "mysqli - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "MYSQLI_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\..\php_build\include" /I "..\..\..\php_build\include\mysqli" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "COMPILE_DL_MYSQLI" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D "PHP_MYSQLI_EXPORTS" /D "HAVE_ZLIB" /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "_DEBUG"
-# ADD RSC /l 0x407 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 php5ts_debug.lib zlib.lib libmySQL.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_mysqli.dll" /pdbtype:sept /libpath:"..\..\Debug_TS" /libpath:"..\..\..\php_build\release"
-
-!ENDIF
-
-# Begin Target
-
-# Name "mysqli - Win32 Release_TS"
-# Name "mysqli - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\mysqli.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\mysqli_api.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\mysqli_fe.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\mysqli_nonapi.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_mysqli.h
-# End Source File
-# End Group
-# End Target
-# End Project
diff --git a/ext/mysqli/mysqli_api.c b/ext/mysqli/mysqli_api.c
index d8596c9620..4eff098999 100644
--- a/ext/mysqli/mysqli_api.c
+++ b/ext/mysqli/mysqli_api.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -30,7 +30,7 @@
#include "php_ini.h"
#include "php_globals.h"
#include "ext/standard/info.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#include "php_mysqli_structs.h"
#include "mysqli_priv.h"
diff --git a/ext/mysqli/mysqli_driver.c b/ext/mysqli/mysqli_driver.c
index cb8a477be4..95096f4a61 100644
--- a/ext/mysqli/mysqli_driver.c
+++ b/ext/mysqli/mysqli_driver.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqli/mysqli_embedded.c b/ext/mysqli/mysqli_embedded.c
index 898287d3fb..4c1c4a37a5 100644
--- a/ext/mysqli/mysqli_embedded.c
+++ b/ext/mysqli/mysqli_embedded.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqli/mysqli_exception.c b/ext/mysqli/mysqli_exception.c
index 30ed75ddb7..ec86b9d740 100644
--- a/ext/mysqli/mysqli_exception.c
+++ b/ext/mysqli/mysqli_exception.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqli/mysqli_fe.c b/ext/mysqli/mysqli_fe.c
index e099fe7194..2b6c99b9c7 100644
--- a/ext/mysqli/mysqli_fe.c
+++ b/ext/mysqli/mysqli_fe.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqli/mysqli_fe.h b/ext/mysqli/mysqli_fe.h
index 9a9f851248..f5ca0963b5 100644
--- a/ext/mysqli/mysqli_fe.h
+++ b/ext/mysqli/mysqli_fe.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqli/mysqli_libmysql.h b/ext/mysqli/mysqli_libmysql.h
index 5e7f730aec..a22899185a 100644
--- a/ext/mysqli/mysqli_libmysql.h
+++ b/ext/mysqli/mysqli_libmysql.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqli/mysqli_mysqlnd.h b/ext/mysqli/mysqli_mysqlnd.h
index b6d23d9ef1..a1656e59eb 100644
--- a/ext/mysqli/mysqli_mysqlnd.h
+++ b/ext/mysqli/mysqli_mysqlnd.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2009 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqli/mysqli_nonapi.c b/ext/mysqli/mysqli_nonapi.c
index 9c9a109ba2..db0d0ee677 100644
--- a/ext/mysqli/mysqli_nonapi.c
+++ b/ext/mysqli/mysqli_nonapi.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -29,7 +29,7 @@
#include "php.h"
#include "php_ini.h"
#include "ext/standard/info.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#include "php_mysqli_structs.h"
#include "mysqli_priv.h"
diff --git a/ext/mysqli/mysqli_priv.h b/ext/mysqli/mysqli_priv.h
index b240cfab09..cff28400ed 100644
--- a/ext/mysqli/mysqli_priv.h
+++ b/ext/mysqli/mysqli_priv.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqli/mysqli_prop.c b/ext/mysqli/mysqli_prop.c
index c1fa0a17d6..1354e0db93 100644
--- a/ext/mysqli/mysqli_prop.c
+++ b/ext/mysqli/mysqli_prop.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -84,7 +84,7 @@ static zval *__func(mysqli_object *obj, zval *retval TSRMLS_DC) \
if (l < ZEND_LONG_MAX) {\
ZVAL_LONG(retval, (zend_long) l);\
} else { \
- ZVAL_STR(retval, strpprintf(0, __ret_type_sprint_mod, l)); \
+ ZVAL_NEW_STR(retval, strpprintf(0, __ret_type_sprint_mod, l)); \
} \
}\
return retval;\
@@ -170,7 +170,7 @@ static zval *link_affected_rows_read(mysqli_object *obj, zval *retval TSRMLS_DC)
if (rc < ZEND_LONG_MAX) {
ZVAL_LONG(retval, (zend_long) rc);
} else {
- ZVAL_STR(retval, strpprintf(0, MYSQLI_LLU_SPEC, rc));
+ ZVAL_NEW_STR(retval, strpprintf(0, MYSQLI_LLU_SPEC, rc));
}
}
return retval;
@@ -357,7 +357,7 @@ static zval *stmt_affected_rows_read(mysqli_object *obj, zval *retval TSRMLS_DC)
if (rc < ZEND_LONG_MAX) {
ZVAL_LONG(retval, (zend_long) rc);
} else {
- ZVAL_STR(retval, strpprintf(0, MYSQLI_LLU_SPEC, rc));
+ ZVAL_NEW_STR(retval, strpprintf(0, MYSQLI_LLU_SPEC, rc));
}
}
return retval;
diff --git a/ext/mysqli/mysqli_report.c b/ext/mysqli/mysqli_report.c
index 7703465e21..ceec68efb4 100644
--- a/ext/mysqli/mysqli_report.c
+++ b/ext/mysqli/mysqli_report.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqli/mysqli_result_iterator.c b/ext/mysqli/mysqli_result_iterator.c
index 615ba94bbf..5caa926b47 100644
--- a/ext/mysqli/mysqli_result_iterator.c
+++ b/ext/mysqli/mysqli_result_iterator.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqli/mysqli_warning.c b/ext/mysqli/mysqli_warning.c
index a72c97b596..084bc58581 100644
--- a/ext/mysqli/mysqli_warning.c
+++ b/ext/mysqli/mysqli_warning.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -28,7 +28,7 @@
#include "php_mysqli_structs.h"
#include "mysqli_priv.h"
-/* Define these in the PHP5 tree to make merging easy process */
+/* Define these in the PHP7 tree to make merging easy process */
#define Zzend_string_dupLICATE (1<<0)
#define ZSTR_AUTOFREE (1<<1)
diff --git a/ext/mysqli/php_mysqli.h b/ext/mysqli/php_mysqli.h
index e036cf42b7..566bdd7004 100644
--- a/ext/mysqli/php_mysqli.h
+++ b/ext/mysqli/php_mysqli.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqli/php_mysqli_structs.h b/ext/mysqli/php_mysqli_structs.h
index 9570952ec0..d815df3eee 100644
--- a/ext/mysqli/php_mysqli_structs.h
+++ b/ext/mysqli/php_mysqli_structs.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd.c b/ext/mysqlnd/mysqlnd.c
index 74a8b721f2..41f34e366a 100644
--- a/ext/mysqlnd/mysqlnd.c
+++ b/ext/mysqlnd/mysqlnd.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -27,7 +27,7 @@
#include "mysqlnd_statistics.h"
#include "mysqlnd_charset.h"
#include "mysqlnd_debug.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
/*
TODO :
@@ -2496,7 +2496,7 @@ MYSQLND_METHOD(mysqlnd_conn_data, set_client_option_2d)(MYSQLND_CONN_DATA * cons
DBG_INF_FMT("Adding [%s][%s]", key, value);
{
zval attrz;
- ZVAL_STR(&attrz, zend_string_init(value, strlen(value), 1));
+ ZVAL_NEW_STR(&attrz, zend_string_init(value, strlen(value), 1));
zend_hash_str_update(conn->options->connect_attr, key, strlen(key), &attrz);
}
break;
@@ -2798,7 +2798,7 @@ MYSQLND_METHOD(mysqlnd_conn_data, tx_begin)(MYSQLND_CONN_DATA * conn, const unsi
smart_str_appendl(&tmp_str, "WITH CONSISTENT SNAPSHOT", sizeof("WITH CONSISTENT SNAPSHOT") - 1);
}
if (mode & (TRANS_START_READ_WRITE | TRANS_START_READ_ONLY)) {
- unsigned long server_version = conn->m->get_server_version(conn TSRMLS_CC);
+ zend_ulong server_version = conn->m->get_server_version(conn TSRMLS_CC);
if (server_version < 50605L) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "This server version doesn't support 'READ WRITE' and 'READ ONLY'. Minimum 5.6.5 is required");
smart_str_free(&tmp_str);
diff --git a/ext/mysqlnd/mysqlnd.h b/ext/mysqlnd/mysqlnd.h
index c70934be4d..1a23781eb0 100644
--- a/ext/mysqlnd/mysqlnd.h
+++ b/ext/mysqlnd/mysqlnd.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -264,8 +264,6 @@ PHPAPI void _mysqlnd_get_client_stats(zval *return_value TSRMLS_DC ZEND_FILE_L
#define MYSQLND_METHOD_PRIVATE(class, method) php_##class##_##method##_priv
ZEND_BEGIN_MODULE_GLOBALS(mysqlnd)
- zend_bool collect_statistics;
- zend_bool collect_memory_statistics;
char * debug; /* The actual string */
char * trace_alloc_settings; /* The actual string */
MYSQLND_DEBUG * dbg; /* The DBG object for standard tracing */
@@ -283,6 +281,8 @@ ZEND_BEGIN_MODULE_GLOBALS(mysqlnd)
zend_long debug_realloc_fail_threshold;
char * sha256_server_public_key;
zend_bool fetch_data_copy;
+ zend_bool collect_statistics;
+ zend_bool collect_memory_statistics;
ZEND_END_MODULE_GLOBALS(mysqlnd)
PHPAPI ZEND_EXTERN_MODULE_GLOBALS(mysqlnd)
diff --git a/ext/mysqlnd/mysqlnd_alloc.c b/ext/mysqlnd/mysqlnd_alloc.c
index 9cc46dba4a..daa758c043 100644
--- a/ext/mysqlnd/mysqlnd_alloc.c
+++ b/ext/mysqlnd/mysqlnd_alloc.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -539,7 +539,7 @@ void _mysqlnd_free(void *ptr MYSQLND_MEM_D)
#define SMART_STR_START_SIZE 2048
#define SMART_STR_PREALLOC 512
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
/* {{{ _mysqlnd_pestrndup */
diff --git a/ext/mysqlnd/mysqlnd_alloc.h b/ext/mysqlnd/mysqlnd_alloc.h
index eef5988829..b8a14fd1ab 100644
--- a/ext/mysqlnd/mysqlnd_alloc.h
+++ b/ext/mysqlnd/mysqlnd_alloc.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_auth.c b/ext/mysqlnd/mysqlnd_auth.c
index 985357e3bc..255098c4f3 100644
--- a/ext/mysqlnd/mysqlnd_auth.c
+++ b/ext/mysqlnd/mysqlnd_auth.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_block_alloc.c b/ext/mysqlnd/mysqlnd_block_alloc.c
index 100e807bae..705f52ea82 100644
--- a/ext/mysqlnd/mysqlnd_block_alloc.c
+++ b/ext/mysqlnd/mysqlnd_block_alloc.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_block_alloc.h b/ext/mysqlnd/mysqlnd_block_alloc.h
index f9627744d5..c0232d4286 100644
--- a/ext/mysqlnd/mysqlnd_block_alloc.h
+++ b/ext/mysqlnd/mysqlnd_block_alloc.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_charset.c b/ext/mysqlnd/mysqlnd_charset.c
index bf67498eea..97a49e1054 100644
--- a/ext/mysqlnd/mysqlnd_charset.c
+++ b/ext/mysqlnd/mysqlnd_charset.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_charset.h b/ext/mysqlnd/mysqlnd_charset.h
index 87f30d8ba5..ef77b2fb74 100644
--- a/ext/mysqlnd/mysqlnd_charset.h
+++ b/ext/mysqlnd/mysqlnd_charset.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_debug.c b/ext/mysqlnd/mysqlnd_debug.c
index 92121cf247..f1fde4efbb 100644
--- a/ext/mysqlnd/mysqlnd_debug.c
+++ b/ext/mysqlnd/mysqlnd_debug.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_debug.h b/ext/mysqlnd/mysqlnd_debug.h
index fe91082175..bb4ff3e895 100644
--- a/ext/mysqlnd/mysqlnd_debug.h
+++ b/ext/mysqlnd/mysqlnd_debug.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_driver.c b/ext/mysqlnd/mysqlnd_driver.c
index 98826b9ce3..e67d023edb 100644
--- a/ext/mysqlnd/mysqlnd_driver.c
+++ b/ext/mysqlnd/mysqlnd_driver.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_enum_n_def.h b/ext/mysqlnd/mysqlnd_enum_n_def.h
index 0d6a25a419..90068783d9 100644
--- a/ext/mysqlnd/mysqlnd_enum_n_def.h
+++ b/ext/mysqlnd/mysqlnd_enum_n_def.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_ext_plugin.c b/ext/mysqlnd/mysqlnd_ext_plugin.c
index 13f1e294dc..43f1318caa 100644
--- a/ext/mysqlnd/mysqlnd_ext_plugin.c
+++ b/ext/mysqlnd/mysqlnd_ext_plugin.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_ext_plugin.h b/ext/mysqlnd/mysqlnd_ext_plugin.h
index d4a9d6cfc0..c66043da83 100644
--- a/ext/mysqlnd/mysqlnd_ext_plugin.h
+++ b/ext/mysqlnd/mysqlnd_ext_plugin.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_libmysql_compat.h b/ext/mysqlnd/mysqlnd_libmysql_compat.h
index b8ff959d18..db3883cd1e 100644
--- a/ext/mysqlnd/mysqlnd_libmysql_compat.h
+++ b/ext/mysqlnd/mysqlnd_libmysql_compat.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_loaddata.c b/ext/mysqlnd/mysqlnd_loaddata.c
index ab7a1ae9eb..a29a5a186d 100644
--- a/ext/mysqlnd/mysqlnd_loaddata.c
+++ b/ext/mysqlnd/mysqlnd_loaddata.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_net.c b/ext/mysqlnd/mysqlnd_net.c
index 6333875e18..da92acfbff 100644
--- a/ext/mysqlnd/mysqlnd_net.c
+++ b/ext/mysqlnd/mysqlnd_net.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_net.h b/ext/mysqlnd/mysqlnd_net.h
index 76a474bc5f..699dd7f7d5 100644
--- a/ext/mysqlnd/mysqlnd_net.h
+++ b/ext/mysqlnd/mysqlnd_net.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_plugin.c b/ext/mysqlnd/mysqlnd_plugin.c
index 7f5fb9b03f..3bb3c05147 100644
--- a/ext/mysqlnd/mysqlnd_plugin.c
+++ b/ext/mysqlnd/mysqlnd_plugin.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_priv.h b/ext/mysqlnd/mysqlnd_priv.h
index 79e67da464..f05e352baa 100644
--- a/ext/mysqlnd/mysqlnd_priv.h
+++ b/ext/mysqlnd/mysqlnd_priv.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_ps.c b/ext/mysqlnd/mysqlnd_ps.c
index 458ce47ff6..1b2602e6b6 100644
--- a/ext/mysqlnd/mysqlnd_ps.c
+++ b/ext/mysqlnd/mysqlnd_ps.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -115,7 +115,7 @@ MYSQLND_METHOD(mysqlnd_stmt, store_result)(MYSQLND_STMT * const s TSRMLS_DC)
SET_OOM_ERROR(*conn->error_info);
DBG_RETURN(NULL);
}
- memset(set->data, 0, (size_t)(result->stored_data->row_count * result->meta->field_count * sizeof(zval)));;
+ memset(set->data, 0, (size_t)(result->stored_data->row_count * result->meta->field_count * sizeof(zval)));
}
/* Position at the first row */
set->data_cursor = set->data;
diff --git a/ext/mysqlnd/mysqlnd_ps_codec.c b/ext/mysqlnd/mysqlnd_ps_codec.c
index 7cb462960b..e98d1c3a52 100644
--- a/ext/mysqlnd/mysqlnd_ps_codec.c
+++ b/ext/mysqlnd/mysqlnd_ps_codec.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -200,17 +200,27 @@ ps_fetch_float(zval * zv, const MYSQLND_FIELD * const field, unsigned int pack_l
/* The following cast is guaranteed to do the right thing */
dval = (double) d32val;
}
+#elif defined(PHP_WIN32)
+ {
+ /* float datatype on Winows is already 4 byte but has a precision of 7 digits */
+ char num_buf[2048];
+ (void)_gcvt_s(num_buf, 2048, fval, field->decimals >= 31 ? 7 : field->decimals);
+ dval = zend_strtod(num_buf, NULL);
+ }
#else
{
char num_buf[2048]; /* Over allocated */
char *s;
+#ifndef FLT_DIG
+# define FLT_DIG 6
+#endif
/* Convert to string. Ignoring localization, etc.
* Following MySQL's rules. If precision is undefined (NOT_FIXED_DEC i.e. 31)
* or larger than 31, the value is limited to 6 (FLT_DIG).
*/
s = php_gcvt(fval,
- field->decimals >= 31 ? 6 : field->decimals,
+ field->decimals >= 31 ? FLT_DIG : field->decimals,
'.',
'e',
num_buf);
diff --git a/ext/mysqlnd/mysqlnd_result.c b/ext/mysqlnd/mysqlnd_result.c
index ea275be192..610642d8de 100644
--- a/ext/mysqlnd/mysqlnd_result.c
+++ b/ext/mysqlnd/mysqlnd_result.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_result.h b/ext/mysqlnd/mysqlnd_result.h
index f7e22a1d87..700efed83e 100644
--- a/ext/mysqlnd/mysqlnd_result.h
+++ b/ext/mysqlnd/mysqlnd_result.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_result_meta.c b/ext/mysqlnd/mysqlnd_result_meta.c
index 056e3dcef7..447de33ac9 100644
--- a/ext/mysqlnd/mysqlnd_result_meta.c
+++ b/ext/mysqlnd/mysqlnd_result_meta.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_result_meta.h b/ext/mysqlnd/mysqlnd_result_meta.h
index 97720adba1..91388b65a5 100644
--- a/ext/mysqlnd/mysqlnd_result_meta.h
+++ b/ext/mysqlnd/mysqlnd_result_meta.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_reverse_api.c b/ext/mysqlnd/mysqlnd_reverse_api.c
index 49684876a4..553a507818 100644
--- a/ext/mysqlnd/mysqlnd_reverse_api.c
+++ b/ext/mysqlnd/mysqlnd_reverse_api.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_reverse_api.h b/ext/mysqlnd/mysqlnd_reverse_api.h
index 79c0feb60a..58a1ddd087 100644
--- a/ext/mysqlnd/mysqlnd_reverse_api.h
+++ b/ext/mysqlnd/mysqlnd_reverse_api.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_statistics.c b/ext/mysqlnd/mysqlnd_statistics.c
index a664f9b578..e25befbc15 100644
--- a/ext/mysqlnd/mysqlnd_statistics.c
+++ b/ext/mysqlnd/mysqlnd_statistics.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_statistics.h b/ext/mysqlnd/mysqlnd_statistics.h
index 0493d89396..bfc316ec59 100644
--- a/ext/mysqlnd/mysqlnd_statistics.h
+++ b/ext/mysqlnd/mysqlnd_statistics.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/mysqlnd/mysqlnd_structs.h b/ext/mysqlnd/mysqlnd_structs.h
index a50600f4bc..6be8b68034 100644
--- a/ext/mysqlnd/mysqlnd_structs.h
+++ b/ext/mysqlnd/mysqlnd_structs.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -23,7 +23,7 @@
#ifndef MYSQLND_STRUCTS_H
#define MYSQLND_STRUCTS_H
-#include "ext/standard/php_smart_str_public.h"
+#include "zend_smart_str_public.h"
#define MYSQLND_TYPEDEFED_METHODS
@@ -56,9 +56,9 @@ struct st_mysqlnd_memory_pool_chunk
size_t app;
MYSQLND_MEMORY_POOL *pool;
zend_uchar *ptr;
- unsigned int size;
enum_func_status (*resize_chunk)(MYSQLND_MEMORY_POOL_CHUNK * chunk, unsigned int size TSRMLS_DC);
void (*free_chunk)(MYSQLND_MEMORY_POOL_CHUNK * chunk TSRMLS_DC);
+ unsigned int size;
zend_bool from_pool;
};
@@ -869,11 +869,10 @@ struct st_mysqlnd_net_data
struct st_mysqlnd_net
{
- struct st_mysqlnd_net_data * data;
+ /* cmd buffer */
+ MYSQLND_CMD_BUFFER cmd_buffer;
- /* sequence for simple checking of correct packets */
- zend_uchar packet_no;
- zend_uchar compressed_envelope_packet_no;
+ struct st_mysqlnd_net_data * data;
#ifdef MYSQLND_COMPRESSION_ENABLED
MYSQLND_READ_BUFFER * uncompressed_data;
@@ -881,10 +880,11 @@ struct st_mysqlnd_net
void * unused_pad1;
#endif
- /* cmd buffer */
- MYSQLND_CMD_BUFFER cmd_buffer;
-
zend_bool persistent;
+
+ /* sequence for simple checking of correct packets */
+ zend_uchar packet_no;
+ zend_uchar compressed_envelope_packet_no;
};
@@ -994,14 +994,17 @@ struct st_mysqlnd_result_metadata
{
MYSQLND_FIELD *fields;
struct mysqlnd_field_hash_key *zend_hash_keys;
- unsigned int current_field;
- unsigned int field_count;
+
+ struct st_mysqlnd_res_meta_methods * m;
+
+ size_t bit_fields_total_len; /* trailing \0 not counted */
/* We need this to make fast allocs in rowp_read */
unsigned int bit_fields_count;
- size_t bit_fields_total_len; /* trailing \0 not counted */
- zend_bool persistent;
- struct st_mysqlnd_res_meta_methods * m;
+ unsigned int current_field;
+ unsigned int field_count;
+
+ zend_bool persistent;
};
@@ -1055,6 +1058,8 @@ struct st_mysqlnd_buffered_result_c
struct st_mysqlnd_unbuffered_result
{
+ struct st_mysqlnd_result_unbuffered_methods m;
+ uint64_t row_count;
/* For unbuffered (both normal and PS) */
zval *last_row_data;
@@ -1070,14 +1075,13 @@ struct st_mysqlnd_unbuffered_result
struct st_mysqlnd_packet_row * row_packet;
- uint64_t row_count;
+ unsigned int field_count;
+
zend_bool eof_reached;
- unsigned int field_count;
zend_bool ps;
zend_bool persistent;
- struct st_mysqlnd_result_unbuffered_methods m;
};
diff --git a/ext/mysqlnd/mysqlnd_wireprotocol.c b/ext/mysqlnd/mysqlnd_wireprotocol.c
index a6e2517b2b..1d86df7859 100644
--- a/ext/mysqlnd/mysqlnd_wireprotocol.c
+++ b/ext/mysqlnd/mysqlnd_wireprotocol.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -524,7 +524,7 @@ size_t php_mysqlnd_auth_write(void * _packet, MYSQLND_CONN_DATA * conn TSRMLS_DC
int1store(p, packet->auth_data_len);
++p;
/*!!!!! is the buffer big enough ??? */
- if ((sizeof(buffer) - (p - buffer)) < packet->auth_data_len) {
+ if (sizeof(buffer) < (packet->auth_data_len + (p - buffer))) {
DBG_ERR("the stack buffer was not enough!!");
DBG_RETURN(0);
}
@@ -596,7 +596,7 @@ size_t php_mysqlnd_auth_write(void * _packet, MYSQLND_CONN_DATA * conn TSRMLS_DC
} ZEND_HASH_FOREACH_END();
}
#endif
- if ((sizeof(buffer) - (p - buffer)) >= (ca_payload_len + php_mysqlnd_net_store_length_size(ca_payload_len))) {
+ if (sizeof(buffer) >= (ca_payload_len + php_mysqlnd_net_store_length_size(ca_payload_len) + (p - buffer))) {
p = php_mysqlnd_net_store_length(p, ca_payload_len);
#ifdef OLD_CODE
diff --git a/ext/mysqlnd/mysqlnd_wireprotocol.h b/ext/mysqlnd/mysqlnd_wireprotocol.h
index b40808d595..5238715987 100644
--- a/ext/mysqlnd/mysqlnd_wireprotocol.h
+++ b/ext/mysqlnd/mysqlnd_wireprotocol.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -90,20 +90,20 @@ typedef struct st_mysqlnd_packet_greet {
/* Client authenticates */
typedef struct st_mysqlnd_packet_auth {
MYSQLND_PACKET_HEADER header;
- uint32_t client_flags;
- uint32_t max_packet_size;
- uint8_t charset_no;
const char *user;
const zend_uchar *auth_data;
size_t auth_data_len;
const char *db;
const char *auth_plugin_name;
+ uint32_t client_flags;
+ uint32_t max_packet_size;
+ uint8_t charset_no;
/* Here the packet ends. This is user supplied data */
- size_t db_len;
zend_bool send_auth_data;
zend_bool is_change_user_packet;
zend_bool silent;
HashTable *connect_attr;
+ size_t db_len;
} MYSQLND_PACKET_AUTH;
/* Auth response packet */
diff --git a/ext/mysqlnd/php_mysqlnd.c b/ext/mysqlnd/php_mysqlnd.c
index 33c57c23d5..a16018f6ba 100644
--- a/ext/mysqlnd/php_mysqlnd.c
+++ b/ext/mysqlnd/php_mysqlnd.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -27,7 +27,7 @@
#include "mysqlnd_statistics.h"
#include "mysqlnd_reverse_api.h"
#include "ext/standard/info.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
/* {{{ mysqlnd_functions[]
*
diff --git a/ext/mysqlnd/php_mysqlnd.h b/ext/mysqlnd/php_mysqlnd.h
index dc39028900..d81e0a0799 100644
--- a/ext/mysqlnd/php_mysqlnd.h
+++ b/ext/mysqlnd/php_mysqlnd.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2006-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/oci8/oci8.c b/ext/oci8/oci8.c
index 3c63692533..dba13ced93 100644
--- a/ext/oci8/oci8.c
+++ b/ext/oci8/oci8.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -33,7 +33,7 @@
#include "php.h"
#include "ext/standard/info.h"
#include "php_ini.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#if HAVE_OCI8
@@ -1383,9 +1383,9 @@ PHP_MINFO_FUNCTION(oci)
php_info_print_table_start();
php_info_print_table_header(2, "Statistics", "");
- snprintf(buf, sizeof(buf), "%ld", OCI_G(num_persistent));
+ snprintf(buf, sizeof(buf), "%pd", OCI_G(num_persistent));
php_info_print_table_row(2, "Active Persistent Connections", buf);
- snprintf(buf, sizeof(buf), "%ld", OCI_G(num_links));
+ snprintf(buf, sizeof(buf), "%pd", OCI_G(num_links));
php_info_print_table_row(2, "Active Connections", buf);
php_info_print_table_end();
}
@@ -1758,9 +1758,9 @@ void php_oci_do_connect(INTERNAL_FUNCTION_PARAMETERS, int persistent, int exclus
php_oci_connection *connection;
char *username, *password;
char *dbname = NULL, *charset = NULL;
- int username_len = 0, password_len = 0;
- int dbname_len = 0, charset_len = 0;
- long session_mode = OCI_DEFAULT;
+ size_t username_len = 0, password_len = 0;
+ size_t dbname_len = 0, charset_len = 0;
+ zend_long session_mode = OCI_DEFAULT;
/* if a fourth parameter is handed over, it is the charset identifier (but is only used in Oracle 9i+) */
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss|ssl", &username, &username_len, &password, &password_len, &dbname, &dbname_len, &charset, &charset_len, &session_mode) == FAILURE) {
@@ -1789,7 +1789,7 @@ void php_oci_do_connect(INTERNAL_FUNCTION_PARAMETERS, int persistent, int exclus
if (!connection) {
RETURN_FALSE;
}
- RETURN_RESOURCE(connection->id);
+ RETURN_RES(connection->id);
}
/* }}} */
@@ -1799,7 +1799,7 @@ void php_oci_do_connect(INTERNAL_FUNCTION_PARAMETERS, int persistent, int exclus
* The real connect function. Allocates all the resources needed, establishes the connection and
* returns the result handle (or NULL)
*/
-php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char *password, int password_len, char *new_password, int new_password_len, char *dbname, int dbname_len, char *charset, long session_mode, int persistent, int exclusive TSRMLS_DC)
+php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char *password, int password_len, char *new_password, int new_password_len, char *dbname, int dbname_len, char *charset, zend_long session_mode, int persistent, int exclusive TSRMLS_DC)
{
zval *zvp;
zend_resource *le;
@@ -1815,7 +1815,7 @@ php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char
ub2 charsetid_nls_lang = 0;
if (session_mode & ~(OCI_SYSOPER | OCI_SYSDBA | PHP_OCI_CRED_EXT)) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid session mode specified (%ld)", session_mode);
+ php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid session mode specified (%pd)", session_mode);
return NULL;
}
if (session_mode & (OCI_SYSOPER | OCI_SYSDBA | PHP_OCI_CRED_EXT)) {
@@ -1889,7 +1889,7 @@ php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char
smart_str_appendl_ex(&hashed_details, "**", sizeof("**") - 1, 0);
if (password_len) {
- ulong password_hash;
+ zend_ulong password_hash;
password_hash = zend_inline_hash_func(password, password_len);
smart_str_append_unsigned_ex(&hashed_details, password_hash, 0);
}
@@ -1949,9 +1949,8 @@ php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char
int type, link;
void *ptr;
- link = OCI8_PTR_TO_INT(le->ptr);
- ptr = zend_list_find(link, &type); /* PHPNG TODO */
- if (ptr && (type == le_connection)) {
+ ptr = le->ptr; /* PHPNG TODO */
+ if (ptr && (le->type == le_connection)) {
connection = (php_oci_connection *)ptr;
}
}
@@ -1972,7 +1971,7 @@ php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char
*/
if (connection && connection->is_persistent && connection->is_stub) {
if (php_oci_create_session(connection, NULL, dbname, dbname_len, username, username_len, password, password_len, new_password, new_password_len, session_mode TSRMLS_CC)) {
- smart_str_free_ex(&hashed_details, 0);
+ smart_str_free(&hashed_details);
zend_hash_del(&EG(persistent_list), connection->hash_key);
return NULL;
@@ -2007,10 +2006,10 @@ php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char
/* okay, the connection is open and the server is still alive */
connection->used_this_request = 1;
- tmp = (php_oci_connection *)zend_list_find(connection->id, &rsrc_type);
+ tmp = (php_oci_connection *)connection->id->ptr;
if (tmp != NULL && rsrc_type == le_pconnection && tmp->hash_key->len == hashed_details.s->len &&
- memcmp(tmp->hash_key->val, hashed_details.s->val, tmp->hash_key->len) == 0 && zend_list_addref(connection->id) == SUCCESS) {
+ memcmp(tmp->hash_key->val, hashed_details.s->val, tmp->hash_key->len) == 0 && ++GC_REFCOUNT(connection->id) == SUCCESS) {
/* do nothing */
} else {
PHP_OCI_REGISTER_RESOURCE(connection, le_pconnection);
@@ -2020,18 +2019,18 @@ php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char
* decremented in the persistent helper
*/
if (OCI_G(old_oci_close_semantics)) {
- zend_list_addref(connection->id);
+ ++GC_REFCOUNT(connection->id);
}
}
- smart_str_free_ex(&hashed_details, 0);
+ smart_str_free(&hashed_details);
return connection;
}
}
/* server died */
} else {
/* we do not ping non-persistent connections */
- smart_str_free_ex(&hashed_details, 0);
- zend_list_addref(connection->id);
+ smart_str_free(&hashed_details);
+ ++GC_REFCOUNT(connection->id);
return connection;
}
} /* is_open is true? */
@@ -2048,7 +2047,7 @@ php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char
/* We have to do a hash_del but need to preserve the resource if there is a positive
* refcount. Set the data pointer in the list entry to NULL
*/
- if (connection == zend_list_find(connection->id, &rsrc_type) && rsrc_type == le_pconnection) {
+ if (connection == connection->id->ptr && rsrc_type == le_pconnection) {
le->ptr = NULL;
}
@@ -2083,7 +2082,7 @@ php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char
if (OCI_G(max_persistent) != -1 && OCI_G(num_persistent) >= OCI_G(max_persistent)) {
/* all persistent connactions are in use, fallback to non-persistent connection creation */
- php_error_docref(NULL TSRMLS_CC, E_NOTICE, "Too many open persistent connections (%ld)", OCI_G(num_persistent));
+ php_error_docref(NULL TSRMLS_CC, E_NOTICE, "Too many open persistent connections (%pd)", OCI_G(num_persistent));
alloc_non_persistent = 1;
}
}
@@ -2131,7 +2130,7 @@ php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char
if ((session_pool = php_oci_get_spool(username, username_len, password, password_len, dbname, dbname_len, charsetid ? charsetid:charsetid_nls_lang TSRMLS_CC))==NULL)
{
php_oci_connection_close(connection TSRMLS_CC);
- smart_str_free_ex(&hashed_details, 0);
+ smart_str_free(&hashed_details);
return NULL;
}
}
@@ -2142,7 +2141,7 @@ php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char
/* Mark password as unchanged by PHP during the duration of the database session */
connection->passwd_changed = 0;
- smart_str_free_ex(&hashed_details, 0);
+ smart_str_free(&hashed_details);
if (charsetid) {
connection->charset = charsetid;
@@ -2181,14 +2180,14 @@ php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char
* refcount is decremented in the persistent helper
*/
if (OCI_G(old_oci_close_semantics)) {
- zend_list_addref(connection->id);
+ ++GC_REFCOUNT(connection->id);
}
zend_hash_update_mem(&EG(persistent_list), connection->hash_key, (void *)&new_le, sizeof(zend_resource));
OCI_G(num_persistent)++;
OCI_G(num_links)++;
} else if (!exclusive) {
PHP_OCI_REGISTER_RESOURCE(connection, le_connection);
- new_le.ptr = OCI8_INT_TO_PTR(connection->id);
+ new_le.ptr = connection->id;
new_le.type = le_index_ptr;
zend_hash_update_mem(&EG(regular_list), connection->hash_key, (void *)&new_le, sizeof(zend_resource));
OCI_G(num_links)++;
@@ -2564,15 +2563,15 @@ int php_oci_column_to_zval(php_oci_out_column *column, zval *value, int mode TSR
}
if (column->is_cursor) { /* REFCURSOR -> simply return the statement id */
- ZVAL_RESOURCE(value, column->stmtid);
- zend_list_addref(column->stmtid);
+ zend_register_resource(value, column->stmtid, 0 TSRMLS_CC); /* XXX type correct? */
+ ++GC_REFCOUNT(column->stmtid);
} else if (column->is_descr) {
if (column->data_type != SQLT_RDD) {
int rsrc_type;
/* reset descriptor's length */
- descriptor = (php_oci_descriptor *) zend_list_find(column->descid, &rsrc_type);
+ descriptor = (php_oci_descriptor *) column->descid->ptr;
if (!descriptor || rsrc_type != le_descriptor) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find LOB descriptor #%d", column->descid);
@@ -2608,7 +2607,7 @@ int php_oci_column_to_zval(php_oci_out_column *column, zval *value, int mode TSR
/* return the locator */
object_init_ex(value, oci_lob_class_entry_ptr);
add_property_resource(value, "descriptor", column->descid);
- zend_list_addref(column->descid);
+ ++GC_REFCOUNT(column->descid);
}
} else {
switch (column->retcode) {
@@ -2648,7 +2647,7 @@ void php_oci_fetch_row (INTERNAL_FUNCTION_PARAMETERS, int mode, int expected_arg
php_oci_out_column *column;
ub4 nrows = 1;
int i;
- long fetch_mode = 0;
+ zend_long fetch_mode = 0;
if (expected_args > 2) {
/* only for ocifetchinto BC */
@@ -2762,19 +2761,18 @@ void php_oci_fetch_row (INTERNAL_FUNCTION_PARAMETERS, int mode, int expected_arg
}
if (!(column->indicator == -1)) {
- zval *element;
+ zval element;
- MAKE_STD_ZVAL(element);
- php_oci_column_to_zval(column, element, fetch_mode TSRMLS_CC);
+ php_oci_column_to_zval(column, &element, fetch_mode TSRMLS_CC);
if (fetch_mode & PHP_OCI_NUM || !(fetch_mode & PHP_OCI_ASSOC)) {
- add_index_zval(return_value, i, element);
+ add_index_zval(return_value, i, &element);
}
if (fetch_mode & PHP_OCI_ASSOC) {
if (fetch_mode & PHP_OCI_NUM) {
- Z_ADDREF_P(element);
+ Z_ADDREF(element);
}
- add_assoc_zval(return_value, column->name, element);
+ add_assoc_zval(return_value, column->name, &element);
}
} else {
@@ -2789,7 +2787,7 @@ void php_oci_fetch_row (INTERNAL_FUNCTION_PARAMETERS, int mode, int expected_arg
if (expected_args > 2) {
/* Only for ocifetchinto BC. In all other cases we return array, not long */
- REPLACE_ZVAL_VALUE(&array, return_value, 1); /* copy return_value to given reference */
+ ZVAL_COPY_VALUE(array, return_value); /* copy return_value to given reference */
zval_dtor(return_value);
RETURN_LONG(statement->ncolumns);
}
@@ -2976,6 +2974,7 @@ static php_oci_spool *php_oci_get_spool(char *username, int username_len, char *
zend_resource spool_le = {0};
zend_resource *spool_out_le = NULL;
zend_bool iserror = 0;
+ zval *spool_out_zv = NULL;
/* {{{ Create the spool hash key */
smart_str_appendl_ex(&spool_hashed_details, "oci8spool***", sizeof("oci8spool***") - 1, 0);
@@ -2987,7 +2986,7 @@ static php_oci_spool *php_oci_get_spool(char *username, int username_len, char *
}
smart_str_appendl_ex(&spool_hashed_details, "**", sizeof("**") - 1, 0);
if (password_len) {
- ulong password_hash;
+ zend_ulong password_hash;
password_hash = zend_inline_hash_func(password, password_len);
smart_str_append_unsigned_ex(&spool_hashed_details, password_hash, 0);
}
@@ -3007,7 +3006,12 @@ static php_oci_spool *php_oci_get_spool(char *username, int username_len, char *
php_strtolower(spool_hashed_details.s->val, spool_hashed_details.s->len);
/* }}} */
- if ((spool_out_le = zend_hash_find(&EG(persistent_list), spool_hashed_details.s)) == NULL) {
+ spool_out_zv = zend_hash_find(&EG(persistent_list), spool_hashed_details.s);
+ if (spool_out_zv != NULL) {
+ spool_out_le = Z_RES_P(spool_out_zv);
+ }
+
+ if (spool_out_le == NULL) {
session_pool = php_oci_create_spool(username, username_len, password, password_len, dbname, dbname_len, spool_hashed_details.s, charsetid TSRMLS_CC);
@@ -3027,7 +3031,7 @@ static php_oci_spool *php_oci_get_spool(char *username, int username_len, char *
}
exit_get_spool:
- smart_str_free_ex(&spool_hashed_details, 0);
+ smart_str_free(&spool_hashed_details);
if (iserror && session_pool) {
php_oci_spool_close(session_pool TSRMLS_CC);
session_pool = NULL;
diff --git a/ext/oci8/oci8.dsp b/ext/oci8/oci8.dsp
deleted file mode 100644
index f0b27fa824..0000000000
--- a/ext/oci8/oci8.dsp
+++ /dev/null
@@ -1,133 +0,0 @@
-# Microsoft Developer Studio Project File - Name="oci8" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=oci8 - Win32 Release_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "oci8.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "oci8.mak" CFG="oci8 - Win32 Release_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "oci8 - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "oci8 - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "oci8 - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\TSRM" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D ZTS=1 /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\..\\" /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\php_build\include\instantclient" /D ZEND_DEBUG=0 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_OCI8=1 /D HAVE_OCI8_TEMP_LOB=1 /D HAVE_OCI8_ATTR_STATEMENT=1 /D COMPILE_DL_OCI8=1 /D PHP_OCI8_HAVE_COLLECTIONS=1 /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib /nologo /dll /machine:I386
-# ADD LINK32 php4ts.lib oci.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_oci8.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\..\php_build\lib\instantclient" /libpath:"..\..\Release_TS_Inline"
-
-!ELSEIF "$(CFG)" == "oci8 - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D ZTS=1 /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /GX /ZI /Od /I "..\..\\" /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\php_build\include\instantclient" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "FTP_EXPORTS" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_OCI8=1 /D HAVE_OCI8_TEMP_LOB=1 /D HAVE_OCI8_ATTR_STATEMENT=1 /D COMPILE_DL_OCI8=1 /D PHP_OCI8_HAVE_COLLECTIONS=1 /FR /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib /nologo /dll /machine:I386
-# ADD LINK32 php4ts_debug.lib oci.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Debug_TS/php_oci8.dll" /libpath:"..\..\Debug_TS" /libpath:"..\..\..\php_build\lib\instantclient"
-
-!ENDIF
-
-# Begin Target
-
-# Name "oci8 - Win32 Release_TS"
-# Name "oci8 - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\oci8.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oci8_collection.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oci8_interface.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oci8_lob.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\oci8_statement.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_oci8.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_oci8_int.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# End Target
-# End Project
diff --git a/ext/oci8/oci8_collection.c b/ext/oci8/oci8_collection.c
index d525ef4a9b..341a983ef5 100644
--- a/ext/oci8/oci8_collection.c
+++ b/ext/oci8/oci8_collection.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -56,7 +56,7 @@ php_oci_collection *php_oci_collection_create(php_oci_connection *connection, ch
collection->connection = connection;
collection->collection = NULL;
- zend_list_addref(collection->connection->id);
+ ++GC_REFCOUNT(collection->connection->id);
/* get type handle by name */
PHP_OCI_CALL_RETURN(errstatus, OCITypeByName,
@@ -260,7 +260,7 @@ int php_oci_collection_size(php_oci_collection *collection, sb4 *size TSRMLS_DC)
/* {{{ php_oci_collection_max()
Return max number of elements in the collection */
-int php_oci_collection_max(php_oci_collection *collection, long *max TSRMLS_DC)
+int php_oci_collection_max(php_oci_collection *collection, zend_long *max TSRMLS_DC)
{
php_oci_connection *connection = collection->connection;
@@ -273,7 +273,7 @@ int php_oci_collection_max(php_oci_collection *collection, long *max TSRMLS_DC)
/* {{{ php_oci_collection_trim()
Trim collection to the given number of elements */
-int php_oci_collection_trim(php_oci_collection *collection, long trim_size TSRMLS_DC)
+int php_oci_collection_trim(php_oci_collection *collection, zend_long trim_size TSRMLS_DC)
{
php_oci_connection *connection = collection->connection;
sword errstatus;
@@ -473,7 +473,7 @@ int php_oci_collection_append(php_oci_collection *collection, char *element, int
/* {{{ php_oci_collection_element_get()
Get the element with the given index */
-int php_oci_collection_element_get(php_oci_collection *collection, long index, zval **result_element TSRMLS_DC)
+int php_oci_collection_element_get(php_oci_collection *collection, zend_long index, zval *result_element TSRMLS_DC)
{
php_oci_connection *connection = collection->connection;
dvoid *element;
@@ -483,8 +483,7 @@ int php_oci_collection_element_get(php_oci_collection *collection, long index, z
ub4 buff_len = 1024;
sword errstatus;
- MAKE_STD_ZVAL(*result_element);
- ZVAL_NULL(*result_element);
+ ZVAL_NULL(result_element);
connection->errcode = 0; /* retain backwards compat with OCI8 1.4 */
@@ -503,13 +502,11 @@ int php_oci_collection_element_get(php_oci_collection *collection, long index, z
if (errstatus != OCI_SUCCESS) {
connection->errcode = php_oci_error(connection->err, errstatus TSRMLS_CC);
PHP_OCI_HANDLE_ERROR(connection, connection->errcode);
- FREE_ZVAL(*result_element);
return 1;
}
if (exists == 0) {
/* element doesn't exist */
- FREE_ZVAL(*result_element);
return 1;
}
@@ -525,12 +522,11 @@ int php_oci_collection_element_get(php_oci_collection *collection, long index, z
if (errstatus != OCI_SUCCESS) {
connection->errcode = php_oci_error(connection->err, errstatus TSRMLS_CC);
PHP_OCI_HANDLE_ERROR(connection, connection->errcode);
- FREE_ZVAL(*result_element);
return 1;
}
- ZVAL_STRINGL(*result_element, (char *)buff, buff_len, 1);
- Z_STRVAL_P(*result_element)[buff_len] = '\0';
+ ZVAL_STRINGL(result_element, (char *)buff, buff_len);
+ Z_STRVAL_P(result_element)[buff_len] = '\0';
return 0;
break;
@@ -543,7 +539,7 @@ int php_oci_collection_element_get(php_oci_collection *collection, long index, z
PHP_OCI_CALL_RETURN(str, OCIStringPtr, (connection->env, oci_string));
if (str) {
- ZVAL_STRING(*result_element, (char *)str, 1);
+ ZVAL_STRING(result_element, (char *)str);
}
return 0;
}
@@ -568,18 +564,16 @@ int php_oci_collection_element_get(php_oci_collection *collection, long index, z
if (errstatus != OCI_SUCCESS) {
connection->errcode = php_oci_error(connection->err, errstatus TSRMLS_CC);
PHP_OCI_HANDLE_ERROR(connection, connection->errcode);
- FREE_ZVAL(*result_element);
return 1;
}
- ZVAL_DOUBLE(*result_element, double_number);
+ ZVAL_DOUBLE(result_element, double_number);
return 0;
}
break;
default:
php_error_docref(NULL TSRMLS_CC, E_NOTICE, "Unknown or unsupported type of element: %d", collection->element_typecode);
- FREE_ZVAL(*result_element);
return 1;
break;
}
@@ -590,7 +584,7 @@ int php_oci_collection_element_get(php_oci_collection *collection, long index, z
/* {{{ php_oci_collection_element_set_null()
Set the element with the given index to NULL */
-int php_oci_collection_element_set_null(php_oci_collection *collection, long index TSRMLS_DC)
+int php_oci_collection_element_set_null(php_oci_collection *collection, zend_long index TSRMLS_DC)
{
OCIInd null_index = OCI_IND_NULL;
php_oci_connection *connection = collection->connection;
@@ -611,7 +605,7 @@ int php_oci_collection_element_set_null(php_oci_collection *collection, long ind
/* {{{ php_oci_collection_element_set_date()
Change element's value to the given DATE */
-int php_oci_collection_element_set_date(php_oci_collection *collection, long index, char *date, int date_len TSRMLS_DC)
+int php_oci_collection_element_set_date(php_oci_collection *collection, zend_long index, char *date, int date_len TSRMLS_DC)
{
OCIInd new_index = OCI_IND_NOTNULL;
OCIDate oci_date;
@@ -652,7 +646,7 @@ int php_oci_collection_element_set_date(php_oci_collection *collection, long ind
/* {{{ php_oci_collection_element_set_number()
Change element's value to the given NUMBER */
-int php_oci_collection_element_set_number(php_oci_collection *collection, long index, char *number, int number_len TSRMLS_DC)
+int php_oci_collection_element_set_number(php_oci_collection *collection, zend_long index, char *number, int number_len TSRMLS_DC)
{
OCIInd new_index = OCI_IND_NOTNULL;
double element_double;
@@ -694,7 +688,7 @@ int php_oci_collection_element_set_number(php_oci_collection *collection, long i
/* {{{ php_oci_collection_element_set_string()
Change element's value to the given string */
-int php_oci_collection_element_set_string(php_oci_collection *collection, long index, char *element, int element_len TSRMLS_DC)
+int php_oci_collection_element_set_string(php_oci_collection *collection, zend_long index, char *element, int element_len TSRMLS_DC)
{
OCIInd new_index = OCI_IND_NOTNULL;
OCIString *ocistr = (OCIString *)0;
@@ -733,7 +727,7 @@ int php_oci_collection_element_set_string(php_oci_collection *collection, long i
/* {{{ php_oci_collection_element_set()
Collection element setter */
-int php_oci_collection_element_set(php_oci_collection *collection, long index, char *value, int value_len TSRMLS_DC)
+int php_oci_collection_element_set(php_oci_collection *collection, zend_long index, char *value, int value_len TSRMLS_DC)
{
if (value_len == 0) {
return php_oci_collection_element_set_null(collection, index TSRMLS_CC);
diff --git a/ext/oci8/oci8_interface.c b/ext/oci8/oci8_interface.c
index 198493b946..6c73ad0a32 100644
--- a/ext/oci8/oci8_interface.c
+++ b/ext/oci8/oci8_interface.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -51,8 +51,8 @@ PHP_FUNCTION(oci_define_by_name)
{
zval *stmt, *var;
char *name;
- int name_len;
- long type = 0;
+ size_t name_len;
+ zend_long type = 0;
php_oci_statement *statement;
php_oci_define *define, *tmp_define;
@@ -74,7 +74,8 @@ PHP_FUNCTION(oci_define_by_name)
define = ecalloc(1,sizeof(php_oci_define));
- if (zend_hash_add(statement->defines, name, name_len, define, sizeof(php_oci_define), (void **)&tmp_define) == SUCCESS) {
+ //if (zend_hash_add(statement->defines, name, name_len, define, sizeof(php_oci_define), (void **)&tmp_define) == SUCCESS) {
+ if ((tmp_define = zend_hash_add_new_ptr(statement->defines, zend_string_init(name, name_len, 0), define)) != NULL) {
efree(define);
define = tmp_define;
} else {
@@ -85,8 +86,8 @@ PHP_FUNCTION(oci_define_by_name)
define->name = (text*) estrndup(name, name_len);
define->name_len = name_len;
define->type = type;
- define->zval = var;
- zval_add_ref(&var);
+ memmove(&define->zval, var, sizeof(zval));
+ Z_ADDREF_P(var);
RETURN_TRUE;
}
@@ -98,8 +99,8 @@ PHP_FUNCTION(oci_define_by_name)
PHP_FUNCTION(oci_bind_by_name)
{
ub2 bind_type = SQLT_CHR; /* unterminated string */
- int name_len;
- long maxlen = -1, type = 0;
+ size_t name_len;
+ zend_long maxlen = -1, type = 0;
char *name;
zval *z_statement;
zval *bind_var = NULL;
@@ -126,10 +127,10 @@ PHP_FUNCTION(oci_bind_by_name)
Bind a PHP array to an Oracle PL/SQL type by name */
PHP_FUNCTION(oci_bind_array_by_name)
{
- int name_len;
- long max_item_len = -1;
- long max_array_len = 0;
- long type = SQLT_AFC;
+ size_t name_len;
+ zend_long max_item_len = -1;
+ zend_long max_array_len = 0;
+ zend_long type = SQLT_AFC;
char *name;
zval *z_statement;
zval *bind_var = NULL;
@@ -161,7 +162,7 @@ PHP_FUNCTION(oci_bind_array_by_name)
Deletes large object description */
PHP_FUNCTION(oci_free_descriptor)
{
- zval **tmp, *z_descriptor = getThis();
+ zval *tmp, *z_descriptor = getThis();
php_oci_descriptor *descriptor;
if (!getThis()) {
@@ -170,12 +171,12 @@ PHP_FUNCTION(oci_free_descriptor)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp, descriptor);
zend_list_delete(descriptor->id);
RETURN_TRUE;
@@ -186,11 +187,11 @@ PHP_FUNCTION(oci_free_descriptor)
Saves a large object */
PHP_FUNCTION(oci_lob_save)
{
- zval **tmp, *z_descriptor = getThis();
+ zval *tmp, *z_descriptor = getThis();
php_oci_descriptor *descriptor;
char *data;
- int data_len;
- long offset = 0;
+ size_t data_len;
+ zend_long offset = 0;
ub4 bytes_written;
if (getThis()) {
@@ -204,12 +205,12 @@ PHP_FUNCTION(oci_lob_save)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp, descriptor);
if (offset < 0) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Offset parameter must be greater than or equal to 0");
@@ -227,10 +228,10 @@ PHP_FUNCTION(oci_lob_save)
Loads file into a LOB */
PHP_FUNCTION(oci_lob_import)
{
- zval **tmp, *z_descriptor = getThis();
+ zval *tmp, *z_descriptor = getThis();
php_oci_descriptor *descriptor;
char *filename;
- int filename_len;
+ size_t filename_len;
if (getThis()) {
#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION > 3) || (PHP_MAJOR_VERSION > 5)
@@ -259,12 +260,12 @@ PHP_FUNCTION(oci_lob_import)
}
#endif
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp, descriptor);
if (php_oci_lob_import(descriptor, filename TSRMLS_CC)) {
RETURN_FALSE;
@@ -277,7 +278,7 @@ PHP_FUNCTION(oci_lob_import)
Loads a large object */
PHP_FUNCTION(oci_lob_load)
{
- zval **tmp, *z_descriptor = getThis();
+ zval *tmp, *z_descriptor = getThis();
php_oci_descriptor *descriptor;
char *buffer = NULL;
ub4 buffer_len;
@@ -288,18 +289,18 @@ PHP_FUNCTION(oci_lob_load)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp, descriptor);
if (php_oci_lob_read(descriptor, -1, 0, &buffer, &buffer_len TSRMLS_CC)) {
RETURN_FALSE;
}
if (buffer_len > 0) {
- RETURN_STRINGL(buffer, buffer_len, 0);
+ RETURN_STRINGL(buffer, buffer_len);
}
else {
RETURN_EMPTY_STRING();
@@ -311,9 +312,9 @@ PHP_FUNCTION(oci_lob_load)
Reads particular part of a large object */
PHP_FUNCTION(oci_lob_read)
{
- zval **tmp, *z_descriptor = getThis();
+ zval *tmp, *z_descriptor = getThis();
php_oci_descriptor *descriptor;
- long length;
+ zend_long length;
char *buffer;
ub4 buffer_len;
@@ -328,12 +329,12 @@ PHP_FUNCTION(oci_lob_read)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp, descriptor);
if (length <= 0) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Length parameter must be greater than 0");
@@ -344,7 +345,7 @@ PHP_FUNCTION(oci_lob_read)
RETURN_FALSE;
}
if (buffer_len > 0) {
- RETURN_STRINGL(buffer, buffer_len, 0);
+ RETURN_STRINGL(buffer, buffer_len);
}
else {
RETURN_EMPTY_STRING();
@@ -356,7 +357,7 @@ PHP_FUNCTION(oci_lob_read)
Checks if EOF is reached */
PHP_FUNCTION(oci_lob_eof)
{
- zval **tmp, *z_descriptor = getThis();
+ zval *tmp, *z_descriptor = getThis();
php_oci_descriptor *descriptor;
ub4 lob_length;
@@ -366,12 +367,12 @@ PHP_FUNCTION(oci_lob_eof)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp, descriptor);
if (!php_oci_lob_get_length(descriptor, &lob_length TSRMLS_CC) && lob_length >= 0) {
if (lob_length == descriptor->lob_current_position) {
@@ -386,7 +387,7 @@ PHP_FUNCTION(oci_lob_eof)
Tells LOB pointer position */
PHP_FUNCTION(oci_lob_tell)
{
- zval **tmp, *z_descriptor = getThis();
+ zval *tmp, *z_descriptor = getThis();
php_oci_descriptor *descriptor;
if (!getThis()) {
@@ -395,12 +396,12 @@ PHP_FUNCTION(oci_lob_tell)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp, descriptor);
RETURN_LONG(descriptor->lob_current_position);
}
@@ -410,7 +411,7 @@ PHP_FUNCTION(oci_lob_tell)
Rewind pointer of a LOB */
PHP_FUNCTION(oci_lob_rewind)
{
- zval **tmp, *z_descriptor = getThis();
+ zval *tmp, *z_descriptor = getThis();
php_oci_descriptor *descriptor;
if (!getThis()) {
@@ -419,12 +420,12 @@ PHP_FUNCTION(oci_lob_rewind)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp, descriptor);
descriptor->lob_current_position = 0;
@@ -436,9 +437,9 @@ PHP_FUNCTION(oci_lob_rewind)
Moves the pointer of a LOB */
PHP_FUNCTION(oci_lob_seek)
{
- zval **tmp, *z_descriptor = getThis();
+ zval *tmp, *z_descriptor = getThis();
php_oci_descriptor *descriptor;
- long offset, whence = PHP_OCI_SEEK_SET;
+ zend_long offset, whence = PHP_OCI_SEEK_SET;
ub4 lob_length;
if (getThis()) {
@@ -452,12 +453,12 @@ PHP_FUNCTION(oci_lob_seek)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp, descriptor);
if (php_oci_lob_get_length(descriptor, &lob_length TSRMLS_CC)) {
RETURN_FALSE;
@@ -488,7 +489,7 @@ PHP_FUNCTION(oci_lob_seek)
Returns size of a large object */
PHP_FUNCTION(oci_lob_size)
{
- zval **tmp, *z_descriptor = getThis();
+ zval *tmp, *z_descriptor = getThis();
php_oci_descriptor *descriptor;
ub4 lob_length;
@@ -498,12 +499,12 @@ PHP_FUNCTION(oci_lob_size)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp, descriptor);
if (php_oci_lob_get_length(descriptor, &lob_length TSRMLS_CC)) {
RETURN_FALSE;
@@ -516,10 +517,10 @@ PHP_FUNCTION(oci_lob_size)
Writes data to current position of a LOB */
PHP_FUNCTION(oci_lob_write)
{
- zval **tmp, *z_descriptor = getThis();
+ zval *tmp, *z_descriptor = getThis();
php_oci_descriptor *descriptor;
- int data_len;
- long write_len = 0;
+ size_t data_len;
+ zend_long write_len = 0;
ub4 bytes_written;
char *data;
@@ -542,12 +543,12 @@ PHP_FUNCTION(oci_lob_write)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp, descriptor);
if (data_len <= 0) {
RETURN_LONG(0);
@@ -564,7 +565,7 @@ PHP_FUNCTION(oci_lob_write)
Appends data from a LOB to another LOB */
PHP_FUNCTION(oci_lob_append)
{
- zval **tmp_dest, **tmp_from, *z_descriptor_dest = getThis(), *z_descriptor_from;
+ zval *tmp_dest, *tmp_from, *z_descriptor_dest = getThis(), *z_descriptor_from;
php_oci_descriptor *descriptor_dest, *descriptor_from;
if (getThis()) {
@@ -578,18 +579,18 @@ PHP_FUNCTION(oci_lob_append)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor_dest), "descriptor", sizeof("descriptor"), (void **)&tmp_dest) == FAILURE) {
+ if ((tmp_dest = zend_hash_str_find(Z_OBJPROP_P(z_descriptor_dest), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property. The first argument should be valid descriptor object");
RETURN_FALSE;
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor_from), "descriptor", sizeof("descriptor"), (void **)&tmp_from) == FAILURE) {
+ if ((tmp_from = zend_hash_str_find(Z_OBJPROP_P(z_descriptor_from), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property. The second argument should be valid descriptor object");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp_dest, descriptor_dest);
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp_from, descriptor_from);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp_dest, descriptor_dest);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp_from, descriptor_from);
if (php_oci_lob_append(descriptor_dest, descriptor_from TSRMLS_CC)) {
RETURN_FALSE;
@@ -603,9 +604,9 @@ PHP_FUNCTION(oci_lob_append)
Truncates a LOB */
PHP_FUNCTION(oci_lob_truncate)
{
- zval **tmp, *z_descriptor = getThis();
+ zval *tmp, *z_descriptor = getThis();
php_oci_descriptor *descriptor;
- long trim_length = 0;
+ zend_long trim_length = 0;
ub4 ub_trim_length;
if (getThis()) {
@@ -619,7 +620,7 @@ PHP_FUNCTION(oci_lob_truncate)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property");
RETURN_FALSE;
}
@@ -630,7 +631,7 @@ PHP_FUNCTION(oci_lob_truncate)
}
ub_trim_length = (ub4) trim_length;
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp, descriptor);
if (php_oci_lob_truncate(descriptor, ub_trim_length TSRMLS_CC)) {
RETURN_FALSE;
@@ -643,10 +644,10 @@ PHP_FUNCTION(oci_lob_truncate)
Erases a specified portion of the internal LOB, starting at a specified offset */
PHP_FUNCTION(oci_lob_erase)
{
- zval **tmp, *z_descriptor = getThis();
+ zval *tmp, *z_descriptor = getThis();
php_oci_descriptor *descriptor;
ub4 bytes_erased;
- long offset = -1, length = -1;
+ zend_long offset = -1, length = -1;
if (getThis()) {
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|ll", &offset, &length) == FAILURE) {
@@ -679,12 +680,12 @@ PHP_FUNCTION(oci_lob_erase)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp, descriptor);
if (php_oci_lob_erase(descriptor, offset, length, &bytes_erased TSRMLS_CC)) {
RETURN_FALSE;
@@ -697,9 +698,9 @@ PHP_FUNCTION(oci_lob_erase)
Flushes the LOB buffer */
PHP_FUNCTION(oci_lob_flush)
{
- zval **tmp, *z_descriptor = getThis();
+ zval *tmp, *z_descriptor = getThis();
php_oci_descriptor *descriptor;
- long flush_flag = 0;
+ zend_long flush_flag = 0;
if (getThis()) {
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|l", &flush_flag) == FAILURE) {
@@ -712,12 +713,12 @@ PHP_FUNCTION(oci_lob_flush)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp, descriptor);
if (descriptor->buffering == PHP_OCI_LOB_BUFFER_DISABLED) {
/* buffering wasn't enabled, there is nothing to flush */
@@ -735,7 +736,7 @@ PHP_FUNCTION(oci_lob_flush)
Enables/disables buffering for a LOB */
PHP_FUNCTION(ocisetbufferinglob)
{
- zval **tmp, *z_descriptor = getThis();
+ zval *tmp, *z_descriptor = getThis();
php_oci_descriptor *descriptor;
zend_bool flag;
@@ -750,12 +751,12 @@ PHP_FUNCTION(ocisetbufferinglob)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp, descriptor);
if (php_oci_lob_set_buffering(descriptor, flag TSRMLS_CC)) {
RETURN_FALSE;
@@ -768,7 +769,7 @@ PHP_FUNCTION(ocisetbufferinglob)
Returns current state of buffering for a LOB */
PHP_FUNCTION(ocigetbufferinglob)
{
- zval **tmp, *z_descriptor = getThis();
+ zval *tmp, *z_descriptor = getThis();
php_oci_descriptor *descriptor;
if (!getThis()) {
@@ -777,12 +778,12 @@ PHP_FUNCTION(ocigetbufferinglob)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp, descriptor);
if (descriptor->buffering != PHP_OCI_LOB_BUFFER_DISABLED) {
RETURN_TRUE;
@@ -795,26 +796,26 @@ PHP_FUNCTION(ocigetbufferinglob)
Copies data from a LOB to another LOB */
PHP_FUNCTION(oci_lob_copy)
{
- zval **tmp_dest, **tmp_from, *z_descriptor_dest, *z_descriptor_from;
+ zval *tmp_dest, *tmp_from, *z_descriptor_dest, *z_descriptor_from;
php_oci_descriptor *descriptor_dest, *descriptor_from;
- long length = 0;
+ zend_long length = 0;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "OO|l", &z_descriptor_dest, oci_lob_class_entry_ptr, &z_descriptor_from, oci_lob_class_entry_ptr, &length) == FAILURE) {
return;
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor_dest), "descriptor", sizeof("descriptor"), (void **)&tmp_dest) == FAILURE) {
+ if ((tmp_dest = zend_hash_str_find(Z_OBJPROP_P(z_descriptor_dest), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property. The first argument should be valid descriptor object");
RETURN_FALSE;
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor_from), "descriptor", sizeof("descriptor"), (void **)&tmp_from) == FAILURE) {
+ if ((tmp_from = zend_hash_str_find(Z_OBJPROP_P(z_descriptor_from), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property. The second argument should be valid descriptor object");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp_dest, descriptor_dest);
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp_from, descriptor_from);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp_dest, descriptor_dest);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp_from, descriptor_from);
if (ZEND_NUM_ARGS() == 3 && length < 0) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Length parameter must be greater than 0");
@@ -837,7 +838,7 @@ PHP_FUNCTION(oci_lob_copy)
Tests to see if two LOB/FILE locators are equal */
PHP_FUNCTION(oci_lob_is_equal)
{
- zval **tmp_first, **tmp_second, *z_descriptor_first, *z_descriptor_second;
+ zval *tmp_first, *tmp_second, *z_descriptor_first, *z_descriptor_second;
php_oci_descriptor *descriptor_first, *descriptor_second;
boolean is_equal;
@@ -845,18 +846,18 @@ PHP_FUNCTION(oci_lob_is_equal)
return;
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor_first), "descriptor", sizeof("descriptor"), (void **)&tmp_first) == FAILURE) {
+ if ((tmp_first = zend_hash_str_find(Z_OBJPROP_P(z_descriptor_first), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property. The first argument should be valid descriptor object");
RETURN_FALSE;
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor_second), "descriptor", sizeof("descriptor"), (void **)&tmp_second) == FAILURE) {
+ if ((tmp_second = zend_hash_str_find(Z_OBJPROP_P(z_descriptor_second), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property. The second argument should be valid descriptor object");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp_first, descriptor_first);
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp_second, descriptor_second);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp_first, descriptor_first);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp_second, descriptor_second);
if (php_oci_lob_is_equal(descriptor_first, descriptor_second, &is_equal TSRMLS_CC)) {
RETURN_FALSE;
@@ -873,12 +874,12 @@ PHP_FUNCTION(oci_lob_is_equal)
Writes a large object into a file */
PHP_FUNCTION(oci_lob_export)
{
- zval **tmp, *z_descriptor = getThis();
+ zval *tmp, *z_descriptor = getThis();
php_oci_descriptor *descriptor;
char *filename;
char *buffer;
- int filename_len;
- long start = -1, length = -1, block_length;
+ size_t filename_len;
+ zend_long start = -1, length = -1, block_length;
php_stream *stream;
ub4 lob_length;
@@ -927,12 +928,12 @@ PHP_FUNCTION(oci_lob_export)
}
#endif
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp, descriptor);
if (php_oci_lob_get_length(descriptor, &lob_length TSRMLS_CC)) {
RETURN_FALSE;
@@ -1006,11 +1007,11 @@ PHP_FUNCTION(oci_lob_export)
Writes temporary blob */
PHP_FUNCTION(oci_lob_write_temporary)
{
- zval **tmp, *z_descriptor = getThis();
+ zval *tmp, *z_descriptor = getThis();
php_oci_descriptor *descriptor;
char *data;
- int data_len;
- long type = OCI_TEMP_CLOB;
+ size_t data_len;
+ zend_long type = OCI_TEMP_CLOB;
if (getThis()) {
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|l", &data, &data_len, &type) == FAILURE) {
@@ -1023,12 +1024,12 @@ PHP_FUNCTION(oci_lob_write_temporary)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp, descriptor);
if (php_oci_lob_write_tmp(descriptor, type, data, data_len TSRMLS_CC)) {
RETURN_FALSE;
@@ -1041,7 +1042,7 @@ PHP_FUNCTION(oci_lob_write_temporary)
Closes lob descriptor */
PHP_FUNCTION(oci_lob_close)
{
- zval **tmp, *z_descriptor = getThis();
+ zval *tmp, *z_descriptor = getThis();
php_oci_descriptor *descriptor;
if (!getThis()) {
@@ -1050,12 +1051,12 @@ PHP_FUNCTION(oci_lob_close)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_descriptor), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR(*tmp, descriptor);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR(tmp, descriptor);
if (php_oci_lob_close(descriptor TSRMLS_CC)) {
RETURN_FALSE;
@@ -1071,7 +1072,7 @@ PHP_FUNCTION(oci_new_descriptor)
zval *z_connection;
php_oci_connection *connection;
php_oci_descriptor *descriptor;
- long type = OCI_DTYPE_LOB;
+ zend_long type = OCI_DTYPE_LOB;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "r|l", &z_connection, &type) == FAILURE) {
return;
@@ -1146,7 +1147,7 @@ PHP_FUNCTION(oci_field_name)
php_oci_out_column *column;
if ( ( column = php_oci_statement_get_column_helper(INTERNAL_FUNCTION_PARAM_PASSTHRU, 0) ) ) {
- RETURN_STRINGL(column->name, column->name_len, 1);
+ RETURN_STRINGL(column->name, column->name_len);
}
RETURN_FALSE;
}
@@ -1210,64 +1211,64 @@ PHP_FUNCTION(oci_field_type)
switch (column->data_type) {
#ifdef SQLT_TIMESTAMP
case SQLT_TIMESTAMP:
- RETVAL_STRING("TIMESTAMP",1);
+ RETVAL_STRING("TIMESTAMP");
break;
#endif
#ifdef SQLT_TIMESTAMP_TZ
case SQLT_TIMESTAMP_TZ:
- RETVAL_STRING("TIMESTAMP WITH TIMEZONE",1);
+ RETVAL_STRING("TIMESTAMP WITH TIMEZONE");
break;
#endif
#ifdef SQLT_TIMESTAMP_LTZ
case SQLT_TIMESTAMP_LTZ:
- RETVAL_STRING("TIMESTAMP WITH LOCAL TIMEZONE",1);
+ RETVAL_STRING("TIMESTAMP WITH LOCAL TIMEZONE");
break;
#endif
#ifdef SQLT_INTERVAL_YM
case SQLT_INTERVAL_YM:
- RETVAL_STRING("INTERVAL YEAR TO MONTH",1);
+ RETVAL_STRING("INTERVAL YEAR TO MONTH");
break;
#endif
#ifdef SQLT_INTERVAL_DS
case SQLT_INTERVAL_DS:
- RETVAL_STRING("INTERVAL DAY TO SECOND",1);
+ RETVAL_STRING("INTERVAL DAY TO SECOND");
break;
#endif
case SQLT_DAT:
- RETVAL_STRING("DATE",1);
+ RETVAL_STRING("DATE");
break;
case SQLT_NUM:
- RETVAL_STRING("NUMBER",1);
+ RETVAL_STRING("NUMBER");
break;
case SQLT_LNG:
- RETVAL_STRING("LONG",1);
+ RETVAL_STRING("LONG");
break;
case SQLT_BIN:
- RETVAL_STRING("RAW",1);
+ RETVAL_STRING("RAW");
break;
case SQLT_LBI:
- RETVAL_STRING("LONG RAW",1);
+ RETVAL_STRING("LONG RAW");
break;
case SQLT_CHR:
- RETVAL_STRING("VARCHAR2",1);
+ RETVAL_STRING("VARCHAR2");
break;
case SQLT_RSET:
- RETVAL_STRING("REFCURSOR",1);
+ RETVAL_STRING("REFCURSOR");
break;
case SQLT_AFC:
- RETVAL_STRING("CHAR",1);
+ RETVAL_STRING("CHAR");
break;
case SQLT_BLOB:
- RETVAL_STRING("BLOB",1);
+ RETVAL_STRING("BLOB");
break;
case SQLT_CLOB:
- RETVAL_STRING("CLOB",1);
+ RETVAL_STRING("CLOB");
break;
case SQLT_BFILE:
- RETVAL_STRING("BFILE",1);
+ RETVAL_STRING("BFILE");
break;
case SQLT_RDD:
- RETVAL_STRING("ROWID",1);
+ RETVAL_STRING("ROWID");
break;
default:
RETVAL_LONG(column->data_type);
@@ -1318,7 +1319,7 @@ PHP_FUNCTION(oci_execute)
{
zval *z_statement;
php_oci_statement *statement;
- long mode = OCI_COMMIT_ON_SUCCESS;
+ zend_long mode = OCI_COMMIT_ON_SUCCESS;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "r|l", &z_statement, &mode) == FAILURE) {
return;
@@ -1386,13 +1387,14 @@ PHP_FUNCTION(ocifetchinto)
Fetch all rows of result data into an array */
PHP_FUNCTION(oci_fetch_all)
{
- zval *z_statement, *array, *element, *tmp;
+ zval *z_statement, *array;
+ zval element, tmp;
php_oci_statement *statement;
php_oci_out_column **columns;
- zval ***outarrs;
+ zval **outarrs;
ub4 nrows = 1;
int i;
- long rows = 0, flags = 0, skip = 0, maxrows = -1;
+ zend_long rows = 0, flags = 0, skip = 0, maxrows = -1;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rz/|lll", &z_statement, &array, &skip, &maxrows, &flags) == FAILURE) {
return;
@@ -1417,23 +1419,21 @@ PHP_FUNCTION(oci_fetch_all)
}
while (!php_oci_statement_fetch(statement, nrows TSRMLS_CC)) {
- zval *row;
+ zval row;
- MAKE_STD_ZVAL(row);
- array_init(row);
+ array_init(&row);
for (i = 0; i < statement->ncolumns; i++) {
- MAKE_STD_ZVAL(element);
- php_oci_column_to_zval(columns[ i ], element, PHP_OCI_RETURN_LOBS TSRMLS_CC);
+ php_oci_column_to_zval(columns[ i ], &element, PHP_OCI_RETURN_LOBS TSRMLS_CC);
if (flags & PHP_OCI_NUM) {
- zend_hash_next_index_insert(Z_ARRVAL_P(row), &element, sizeof(zval*), NULL);
+ zend_hash_next_index_insert(Z_ARRVAL(row), &element);
} else { /* default to ASSOC */
- zend_symtable_update(Z_ARRVAL_P(row), columns[ i ]->name, columns[ i ]->name_len+1, &element, sizeof(zval*), NULL);
+ zend_symtable_update(Z_ARRVAL(row), zend_string_init(columns[ i ]->name, columns[ i ]->name_len+1, 0), &element);
}
}
- zend_hash_next_index_insert(Z_ARRVAL_P(array), &row, sizeof(zval*), NULL);
+ zend_hash_next_index_insert(Z_ARRVAL_P(array), &row);
rows++;
if (maxrows != -1 && rows == maxrows) {
@@ -1451,25 +1451,22 @@ PHP_FUNCTION(oci_fetch_all)
for (i = 0; i < statement->ncolumns; i++) {
columns[ i ] = php_oci_statement_get_column(statement, i + 1, NULL, 0 TSRMLS_CC);
- MAKE_STD_ZVAL(tmp);
- array_init(tmp);
- zend_hash_next_index_insert(Z_ARRVAL_P(array), &tmp, sizeof(zval*), (void **) &(outarrs[ i ]));
+ array_init(&tmp);
+ outarrs[ i ] = zend_hash_next_index_insert(Z_ARRVAL_P(array), &tmp);
}
} else { /* default to ASSOC */
for (i = 0; i < statement->ncolumns; i++) {
columns[ i ] = php_oci_statement_get_column(statement, i + 1, NULL, 0 TSRMLS_CC);
- MAKE_STD_ZVAL(tmp);
- array_init(tmp);
- zend_symtable_update(Z_ARRVAL_P(array), columns[ i ]->name, columns[ i ]->name_len+1, (void *) &tmp, sizeof(zval*), (void **) &(outarrs[ i ]));
+ array_init(&tmp);
+ outarrs[ i ] = zend_symtable_update(Z_ARRVAL_P(array), zend_string_init(columns[ i ]->name, columns[ i ]->name_len+1, 0), &tmp);
}
}
while (!php_oci_statement_fetch(statement, nrows TSRMLS_CC)) {
for (i = 0; i < statement->ncolumns; i++) {
- MAKE_STD_ZVAL(element);
- php_oci_column_to_zval(columns[ i ], element, PHP_OCI_RETURN_LOBS TSRMLS_CC);
- zend_hash_index_update((*(outarrs[ i ]))->value.ht, rows, (void *)&element, sizeof(zval*), NULL);
+ php_oci_column_to_zval(columns[ i ], &element, PHP_OCI_RETURN_LOBS TSRMLS_CC);
+ zend_hash_index_update(&(outarrs[ i ])->value.arr->ht, rows, &element);
}
rows++;
@@ -1616,7 +1613,7 @@ PHP_FUNCTION(oci_error)
}
if (ZEND_NUM_ARGS() > 0) {
- statement = (php_oci_statement *) zend_fetch_resource(&arg TSRMLS_CC, -1, NULL, NULL, 1, le_statement);
+ statement = (php_oci_statement *) zend_fetch_resource(arg TSRMLS_CC, -1, NULL, NULL, 1, le_statement);
if (statement) {
errh = statement->err;
errcode = statement->errcode;
@@ -1627,14 +1624,14 @@ PHP_FUNCTION(oci_error)
goto go_out;
}
- connection = (php_oci_connection *) zend_fetch_resource(&arg TSRMLS_CC, -1, NULL, NULL, 1, le_connection);
+ connection = (php_oci_connection *) zend_fetch_resource(arg TSRMLS_CC, -1, NULL, NULL, 1, le_connection);
if (connection) {
errh = connection->err;
errcode = connection->errcode;
goto go_out;
}
- connection = (php_oci_connection *) zend_fetch_resource(&arg TSRMLS_CC, -1, NULL, NULL, 1, le_pconnection);
+ connection = (php_oci_connection *) zend_fetch_resource(arg TSRMLS_CC, -1, NULL, NULL, 1, le_pconnection);
if (connection) {
errh = connection->err;
errcode = connection->errcode;
@@ -1696,7 +1693,7 @@ PHP_FUNCTION(oci_parse)
php_oci_connection *connection;
php_oci_statement *statement;
char *query;
- int query_len;
+ size_t query_len;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs", &z_connection, &query, &query_len) == FAILURE) {
return;
@@ -1707,7 +1704,7 @@ PHP_FUNCTION(oci_parse)
statement = php_oci_statement_create(connection, query, query_len TSRMLS_CC);
if (statement) {
- RETURN_RESOURCE(statement->id);
+ RETURN_RES(statement->id);
}
RETURN_FALSE;
}
@@ -1719,7 +1716,7 @@ PHP_FUNCTION(oci_set_prefetch)
{
zval *z_statement;
php_oci_statement *statement;
- long size;
+ zend_long size;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rl", &z_statement, &size) == FAILURE) {
return;
@@ -1746,7 +1743,7 @@ PHP_FUNCTION(oci_set_client_identifier)
zval *z_connection;
php_oci_connection *connection;
char *client_id;
- int client_id_len;
+ size_t client_id_len;
sword errstatus;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs", &z_connection, &client_id, &client_id_len) == FAILURE) {
@@ -1796,7 +1793,7 @@ PHP_FUNCTION(oci_set_edition)
{
#if ((OCI_MAJOR_VERSION > 11) || ((OCI_MAJOR_VERSION == 11) && (OCI_MINOR_VERSION >= 2)))
char *edition;
- int edition_len;
+ size_t edition_len;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &edition, &edition_len) == FAILURE) {
return;
@@ -1830,7 +1827,7 @@ PHP_FUNCTION(oci_set_module_name)
zval *z_connection;
php_oci_connection *connection;
char *module;
- int module_len;
+ size_t module_len;
sword errstatus;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs", &z_connection, &module, &module_len) == FAILURE) {
@@ -1862,7 +1859,7 @@ PHP_FUNCTION(oci_set_action)
zval *z_connection;
php_oci_connection *connection;
char *action;
- int action_len;
+ size_t action_len;
sword errstatus;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs", &z_connection, &action, &action_len) == FAILURE) {
@@ -1894,7 +1891,7 @@ PHP_FUNCTION(oci_set_client_info)
zval *z_connection;
php_oci_connection *connection;
char *client_info;
- int client_info_len;
+ size_t client_info_len;
sword errstatus;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs", &z_connection, &client_info, &client_info_len) == FAILURE) {
@@ -1927,7 +1924,7 @@ PHP_FUNCTION(oci_set_db_operation)
zval *z_connection;
php_oci_connection *connection;
char *dbop_name;
- int dbop_name_len;
+ size_t dbop_name_len;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs", &z_connection, &dbop_name, &dbop_name_len) == FAILURE) {
return;
@@ -1956,7 +1953,7 @@ PHP_FUNCTION(oci_password_change)
{
zval *z_connection;
char *user, *pass_old, *pass_new, *dbname;
- int user_len, pass_old_len, pass_new_len, dbname_len;
+ size_t user_len, pass_old_len, pass_new_len, dbname_len;
php_oci_connection *connection;
#if (PHP_MAJOR_VERSION == 5 && PHP_MINOR_VERSION < 4) || (PHP_MAJOR_VERSION < 5)
@@ -2006,7 +2003,7 @@ PHP_FUNCTION(oci_password_change)
if (!connection) {
RETURN_FALSE;
}
- RETURN_RESOURCE(connection->id);
+ RETURN_RES(connection->id);
}
WRONG_PARAM_COUNT;
}
@@ -2029,7 +2026,7 @@ PHP_FUNCTION(oci_new_cursor)
statement = php_oci_statement_create(connection, NULL, 0 TSRMLS_CC);
if (statement) {
- RETURN_RESOURCE(statement->id);
+ RETURN_RES(statement->id);
}
RETURN_FALSE;
}
@@ -2058,7 +2055,7 @@ PHP_FUNCTION(oci_client_version)
char *version = NULL;
php_oci_client_get_version(&version TSRMLS_CC);
- RETURN_STRING(version, 0);
+ RETURN_STRING(version);
}
/* }}} */
@@ -2080,7 +2077,7 @@ PHP_FUNCTION(oci_server_version)
RETURN_FALSE;
}
- RETURN_STRING(version, 0);
+ RETURN_STRING(version);
}
/* }}} */
@@ -2104,37 +2101,37 @@ PHP_FUNCTION(oci_statement_type)
switch (type) {
case OCI_STMT_SELECT:
- RETVAL_STRING("SELECT",1);
+ RETVAL_STRING("SELECT");
break;
case OCI_STMT_UPDATE:
- RETVAL_STRING("UPDATE",1);
+ RETVAL_STRING("UPDATE");
break;
case OCI_STMT_DELETE:
- RETVAL_STRING("DELETE",1);
+ RETVAL_STRING("DELETE");
break;
case OCI_STMT_INSERT:
- RETVAL_STRING("INSERT",1);
+ RETVAL_STRING("INSERT");
break;
case OCI_STMT_CREATE:
- RETVAL_STRING("CREATE",1);
+ RETVAL_STRING("CREATE");
break;
case OCI_STMT_DROP:
- RETVAL_STRING("DROP",1);
+ RETVAL_STRING("DROP");
break;
case OCI_STMT_ALTER:
- RETVAL_STRING("ALTER",1);
+ RETVAL_STRING("ALTER");
break;
case OCI_STMT_BEGIN:
- RETVAL_STRING("BEGIN",1);
+ RETVAL_STRING("BEGIN");
break;
case OCI_STMT_DECLARE:
- RETVAL_STRING("DECLARE",1);
+ RETVAL_STRING("DECLARE");
break;
case OCI_STMT_CALL:
- RETVAL_STRING("CALL",1);
+ RETVAL_STRING("CALL");
break;
default:
- RETVAL_STRING("UNKNOWN",1);
+ RETVAL_STRING("UNKNOWN");
}
}
/* }}} */
@@ -2164,7 +2161,7 @@ PHP_FUNCTION(oci_num_rows)
Deletes collection object*/
PHP_FUNCTION(oci_free_collection)
{
- zval **tmp, *z_collection = getThis();
+ zval *tmp, *z_collection = getThis();
php_oci_collection *collection;
if (!getThis()) {
@@ -2173,12 +2170,12 @@ PHP_FUNCTION(oci_free_collection)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_collection), "collection", sizeof("collection"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_collection), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find collection property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_COLLECTION(*tmp, collection);
+ PHP_OCI_ZVAL_TO_COLLECTION(tmp, collection);
zend_list_delete(collection->id);
RETURN_TRUE;
@@ -2189,10 +2186,10 @@ PHP_FUNCTION(oci_free_collection)
Append an object to the collection */
PHP_FUNCTION(oci_collection_append)
{
- zval **tmp, *z_collection = getThis();
+ zval *tmp, *z_collection = getThis();
php_oci_collection *collection;
char *value;
- int value_len;
+ size_t value_len;
if (getThis()) {
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &value, &value_len) == FAILURE) {
@@ -2205,12 +2202,12 @@ PHP_FUNCTION(oci_collection_append)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_collection), "collection", sizeof("collection"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_collection), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find collection property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_COLLECTION(*tmp, collection);
+ PHP_OCI_ZVAL_TO_COLLECTION(tmp, collection);
if (php_oci_collection_append(collection, value, value_len TSRMLS_CC)) {
RETURN_FALSE;
@@ -2223,10 +2220,10 @@ PHP_FUNCTION(oci_collection_append)
Retrieve the value at collection index ndx */
PHP_FUNCTION(oci_collection_element_get)
{
- zval **tmp, *z_collection = getThis();
+ zval *tmp, *z_collection = getThis();
php_oci_collection *collection;
- long element_index;
- zval *value;
+ zend_long element_index;
+ zval value;
if (getThis()) {
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &element_index) == FAILURE) {
@@ -2239,20 +2236,18 @@ PHP_FUNCTION(oci_collection_element_get)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_collection), "collection", sizeof("collection"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_collection), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find collection property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_COLLECTION(*tmp, collection);
+ PHP_OCI_ZVAL_TO_COLLECTION(tmp, collection);
if (php_oci_collection_element_get(collection, element_index, &value TSRMLS_CC)) {
RETURN_FALSE;
}
- *return_value = *value;
- zval_copy_ctor(return_value);
- zval_ptr_dtor(&value);
+ RETURN_ZVAL(&value, 1, 1);
}
/* }}} */
@@ -2260,7 +2255,7 @@ PHP_FUNCTION(oci_collection_element_get)
Assign a collection from another existing collection */
PHP_FUNCTION(oci_collection_assign)
{
- zval **tmp_dest, **tmp_from, *z_collection_dest = getThis(), *z_collection_from;
+ zval *tmp_dest, *tmp_from, *z_collection_dest = getThis(), *z_collection_from;
php_oci_collection *collection_dest, *collection_from;
if (getThis()) {
@@ -2274,18 +2269,18 @@ PHP_FUNCTION(oci_collection_assign)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_collection_dest), "collection", sizeof("collection"), (void **)&tmp_dest) == FAILURE) {
+ if ((tmp_dest = zend_hash_str_find(Z_OBJPROP_P(z_collection_dest), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find collection property. The first argument should be valid collection object");
RETURN_FALSE;
}
- if (zend_hash_find(Z_OBJPROP_P(z_collection_from), "collection", sizeof("collection"), (void **)&tmp_from) == FAILURE) {
+ if ((tmp_from = zend_hash_str_find(Z_OBJPROP_P(z_collection_from), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find collection property. The second argument should be valid collection object");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_COLLECTION(*tmp_dest, collection_dest);
- PHP_OCI_ZVAL_TO_COLLECTION(*tmp_from, collection_from);
+ PHP_OCI_ZVAL_TO_COLLECTION(tmp_dest, collection_dest);
+ PHP_OCI_ZVAL_TO_COLLECTION(tmp_from, collection_from);
if (php_oci_collection_assign(collection_dest, collection_from TSRMLS_CC)) {
RETURN_FALSE;
@@ -2298,10 +2293,10 @@ PHP_FUNCTION(oci_collection_assign)
Assign element val to collection at index ndx */
PHP_FUNCTION(oci_collection_element_assign)
{
- zval **tmp, *z_collection = getThis();
+ zval *tmp, *z_collection = getThis();
php_oci_collection *collection;
- int value_len;
- long element_index;
+ size_t value_len;
+ zend_long element_index;
char *value;
if (getThis()) {
@@ -2315,12 +2310,12 @@ PHP_FUNCTION(oci_collection_element_assign)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_collection), "collection", sizeof("collection"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_collection), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find collection property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_COLLECTION(*tmp, collection);
+ PHP_OCI_ZVAL_TO_COLLECTION(tmp, collection);
if (php_oci_collection_element_set(collection, element_index, value, value_len TSRMLS_CC)) {
RETURN_FALSE;
@@ -2333,7 +2328,7 @@ PHP_FUNCTION(oci_collection_element_assign)
Return the size of a collection */
PHP_FUNCTION(oci_collection_size)
{
- zval **tmp, *z_collection = getThis();
+ zval *tmp, *z_collection = getThis();
php_oci_collection *collection;
sb4 size = 0;
@@ -2343,12 +2338,12 @@ PHP_FUNCTION(oci_collection_size)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_collection), "collection", sizeof("collection"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_collection), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find collection property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_COLLECTION(*tmp, collection);
+ PHP_OCI_ZVAL_TO_COLLECTION(tmp, collection);
if (php_oci_collection_size(collection, &size TSRMLS_CC)) {
RETURN_FALSE;
@@ -2361,9 +2356,9 @@ PHP_FUNCTION(oci_collection_size)
Return the max value of a collection. For a varray this is the maximum length of the array */
PHP_FUNCTION(oci_collection_max)
{
- zval **tmp, *z_collection = getThis();
+ zval *tmp, *z_collection = getThis();
php_oci_collection *collection;
- long max;
+ zend_long max;
if (!getThis()) {
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "O", &z_collection, oci_coll_class_entry_ptr) == FAILURE) {
@@ -2371,12 +2366,12 @@ PHP_FUNCTION(oci_collection_max)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_collection), "collection", sizeof("collection"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_collection), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find collection property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_COLLECTION(*tmp, collection);
+ PHP_OCI_ZVAL_TO_COLLECTION(tmp, collection);
if (php_oci_collection_max(collection, &max TSRMLS_CC)) {
RETURN_FALSE;
@@ -2389,9 +2384,9 @@ PHP_FUNCTION(oci_collection_max)
Trim num elements from the end of a collection */
PHP_FUNCTION(oci_collection_trim)
{
- zval **tmp, *z_collection = getThis();
+ zval *tmp, *z_collection = getThis();
php_oci_collection *collection;
- long trim_size;
+ zend_long trim_size;
if (getThis()) {
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &trim_size) == FAILURE) {
@@ -2404,12 +2399,12 @@ PHP_FUNCTION(oci_collection_trim)
}
}
- if (zend_hash_find(Z_OBJPROP_P(z_collection), "collection", sizeof("collection"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(z_collection), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find collection property");
RETURN_FALSE;
}
- PHP_OCI_ZVAL_TO_COLLECTION(*tmp, collection);
+ PHP_OCI_ZVAL_TO_COLLECTION(tmp, collection);
if (php_oci_collection_trim(collection, trim_size TSRMLS_CC)) {
RETURN_FALSE;
@@ -2426,7 +2421,7 @@ PHP_FUNCTION(oci_new_collection)
php_oci_connection *connection;
php_oci_collection *collection;
char *tdo, *schema = NULL;
- int tdo_len, schema_len = 0;
+ size_t tdo_len, schema_len = 0;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rs|s", &z_connection, &tdo, &tdo_len, &schema, &schema_len) == FAILURE) {
return;
@@ -2463,7 +2458,7 @@ PHP_FUNCTION(oci_get_implicit_resultset)
if (imp_statement) {
if (php_oci_statement_execute(imp_statement, (ub4)OCI_DEFAULT TSRMLS_CC))
RETURN_FALSE;
- RETURN_RESOURCE(imp_statement->id);
+ RETURN_RES(imp_statement->id);
}
RETURN_FALSE;
}
diff --git a/ext/oci8/oci8_lob.c b/ext/oci8/oci8_lob.c
index 4982d0f88f..12986a8d3a 100644
--- a/ext/oci8/oci8_lob.c
+++ b/ext/oci8/oci8_lob.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -51,7 +51,7 @@
/* {{{ php_oci_lob_create()
Create LOB descriptor and allocate all the resources needed */
-php_oci_descriptor *php_oci_lob_create (php_oci_connection *connection, long type TSRMLS_DC)
+php_oci_descriptor *php_oci_lob_create (php_oci_connection *connection, zend_long type TSRMLS_DC)
{
php_oci_descriptor *descriptor;
sword errstatus;
@@ -63,7 +63,7 @@ php_oci_descriptor *php_oci_lob_create (php_oci_connection *connection, long typ
/* these three are allowed */
break;
default:
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown descriptor type %ld", type);
+ php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown descriptor type %pd", type);
return NULL;
break;
}
@@ -71,7 +71,7 @@ php_oci_descriptor *php_oci_lob_create (php_oci_connection *connection, long typ
descriptor = ecalloc(1, sizeof(php_oci_descriptor));
descriptor->type = type;
descriptor->connection = connection;
- zend_list_addref(descriptor->connection->id);
+ ++GC_REFCOUNT(descriptor->connection->id);
PHP_OCI_CALL_RETURN(errstatus, OCIDescriptorAlloc, (connection->env, (dvoid*)&(descriptor->descriptor), descriptor->type, (size_t) 0, (dvoid **) 0));
@@ -109,7 +109,7 @@ php_oci_descriptor *php_oci_lob_create (php_oci_connection *connection, long typ
return NULL;
}
- zend_hash_index_update(connection->descriptors,descriptor->index,&descriptor,sizeof(php_oci_descriptor *),NULL);
+ zend_hash_index_update_ptr(connection->descriptors, descriptor->index, &descriptor);
}
return descriptor;
@@ -210,7 +210,7 @@ sb4 php_oci_lob_callback (dvoid *ctxp, CONST dvoid *bufxp, oraub8 len, ub1 piece
/* {{{ php_oci_lob_calculate_buffer()
Work out the size for LOB buffering */
-static inline int php_oci_lob_calculate_buffer(php_oci_descriptor *descriptor, long read_length TSRMLS_DC)
+static inline int php_oci_lob_calculate_buffer(php_oci_descriptor *descriptor, zend_long read_length TSRMLS_DC)
{
php_oci_connection *connection = descriptor->connection;
ub4 chunk_size;
@@ -241,7 +241,7 @@ static inline int php_oci_lob_calculate_buffer(php_oci_descriptor *descriptor, l
/* {{{ php_oci_lob_read()
Read specified portion of the LOB into the buffer */
-int php_oci_lob_read (php_oci_descriptor *descriptor, long read_length, long initial_offset, char **data, ub4 *data_len TSRMLS_DC)
+int php_oci_lob_read (php_oci_descriptor *descriptor, zend_long read_length, zend_long initial_offset, char **data, ub4 *data_len TSRMLS_DC)
{
php_oci_connection *connection = descriptor->connection;
ub4 length = 0;
@@ -513,7 +513,7 @@ int php_oci_lob_get_buffering (php_oci_descriptor *descriptor)
/* {{{ php_oci_lob_copy()
Copy one LOB (or its part) to another one */
-int php_oci_lob_copy (php_oci_descriptor *descriptor_dest, php_oci_descriptor *descriptor_from, long length TSRMLS_DC)
+int php_oci_lob_copy (php_oci_descriptor *descriptor_dest, php_oci_descriptor *descriptor_from, zend_long length TSRMLS_DC)
{
php_oci_connection *connection = descriptor_dest->connection;
ub4 length_dest, length_from, copy_len;
@@ -619,7 +619,7 @@ int php_oci_temp_lob_close (php_oci_descriptor *descriptor TSRMLS_DC)
/* {{{ php_oci_lob_flush()
Flush buffers for the LOB (only if they have been used) */
-int php_oci_lob_flush(php_oci_descriptor *descriptor, long flush_flag TSRMLS_DC)
+int php_oci_lob_flush(php_oci_descriptor *descriptor, zend_long flush_flag TSRMLS_DC)
{
OCILobLocator *lob = descriptor->descriptor;
php_oci_connection *connection = descriptor->connection;
@@ -635,7 +635,7 @@ int php_oci_lob_flush(php_oci_descriptor *descriptor, long flush_flag TSRMLS_DC)
/* only these two are allowed */
break;
default:
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid flag value: %ld", flush_flag);
+ php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid flag value: %pd", flush_flag);
return 1;
break;
}
@@ -806,7 +806,7 @@ int php_oci_lob_append (php_oci_descriptor *descriptor_dest, php_oci_descriptor
/* {{{ php_oci_lob_truncate()
Truncate LOB to the given length */
-int php_oci_lob_truncate (php_oci_descriptor *descriptor, long new_lob_length TSRMLS_DC)
+int php_oci_lob_truncate (php_oci_descriptor *descriptor, zend_long new_lob_length TSRMLS_DC)
{
php_oci_connection *connection = descriptor->connection;
OCILobLocator *lob = descriptor->descriptor;
@@ -848,7 +848,7 @@ int php_oci_lob_truncate (php_oci_descriptor *descriptor, long new_lob_length TS
/* {{{ php_oci_lob_erase()
Erase (or fill with whitespaces, depending on LOB type) the LOB (or its part) */
-int php_oci_lob_erase (php_oci_descriptor *descriptor, long offset, ub4 length, ub4 *bytes_erased TSRMLS_DC)
+int php_oci_lob_erase (php_oci_descriptor *descriptor, zend_long offset, ub4 length, ub4 *bytes_erased TSRMLS_DC)
{
php_oci_connection *connection = descriptor->connection;
OCILobLocator *lob = descriptor->descriptor;
@@ -906,7 +906,7 @@ int php_oci_lob_is_equal (php_oci_descriptor *descriptor_first, php_oci_descript
/* {{{ php_oci_lob_write_tmp()
Create temporary LOB and write data to it */
-int php_oci_lob_write_tmp (php_oci_descriptor *descriptor, long type, char *data, int data_len TSRMLS_DC)
+int php_oci_lob_write_tmp (php_oci_descriptor *descriptor, zend_long type, char *data, int data_len TSRMLS_DC)
{
php_oci_connection *connection = descriptor->connection;
OCILobLocator *lob = descriptor->descriptor;
@@ -919,7 +919,7 @@ int php_oci_lob_write_tmp (php_oci_descriptor *descriptor, long type, char *data
/* only these two are allowed */
break;
default:
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid temporary lob type: %ld", type);
+ php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid temporary lob type: %pd", type);
return 1;
break;
}
diff --git a/ext/oci8/oci8_statement.c b/ext/oci8/oci8_statement.c
index f9d2a3a0ff..7dc0d5ee66 100644
--- a/ext/oci8/oci8_statement.c
+++ b/ext/oci8/oci8_statement.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -106,7 +106,7 @@ php_oci_statement *php_oci_statement_create(php_oci_connection *connection, char
statement->impres_child_stmt = NULL;
statement->impres_count = 0;
statement->impres_flag = PHP_OCI_IMPRES_UNKNOWN; /* may or may not have Implicit Result Set children */
- zend_list_addref(statement->connection->id);
+ ++GC_REFCOUNT(statement->connection->id);
if (OCI_G(default_prefetch) >= 0) {
php_oci_statement_set_prefetch(statement, (ub4)OCI_G(default_prefetch) TSRMLS_CC);
@@ -166,8 +166,8 @@ php_oci_statement *php_oci_get_implicit_resultset(php_oci_statement *statement T
statement2->has_descr = 0;
statement2->stmttype = 0;
- zend_list_addref(statement->id);
- zend_list_addref(statement2->connection->id);
+ Z_ADDREF_P(statement->id);
+ Z_ADDREF_P(statement2->connection->id);
php_oci_statement_set_prefetch(statement2, statement->prefetch_count TSRMLS_CC);
@@ -359,8 +359,8 @@ int php_oci_statement_fetch(php_oci_statement *statement, ub4 nrows TSRMLS_DC)
continue;
}
- zval_dtor(column->define->zval);
- php_oci_column_to_zval(column, column->define->zval, 0 TSRMLS_CC);
+ zval_dtor(&column->define->zval);
+ php_oci_column_to_zval(column, &column->define->zval, 0 TSRMLS_CC);
}
return 0;
@@ -377,7 +377,7 @@ int php_oci_statement_fetch(php_oci_statement *statement, ub4 nrows TSRMLS_DC)
/* {{{ php_oci_statement_get_column()
Get column from the result set */
-php_oci_out_column *php_oci_statement_get_column(php_oci_statement *statement, long column_index, char *column_name, int column_name_len TSRMLS_DC)
+php_oci_out_column *php_oci_statement_get_column(php_oci_statement *statement, zend_long column_index, char *column_name, int column_name_len TSRMLS_DC)
{
php_oci_out_column *column = NULL;
int i;
@@ -396,7 +396,7 @@ php_oci_out_column *php_oci_statement_get_column(php_oci_statement *statement, l
}
}
} else if (column_index != -1) {
- if (zend_hash_index_find(statement->columns, column_index, (void **)&column) == FAILURE) {
+ if ((column = zend_hash_index_find_ptr(statement->columns, column_index)) == NULL) {
return NULL;
}
return column;
@@ -427,7 +427,7 @@ sb4 php_oci_define_callback(dvoid *ctx, OCIDefine *define, ub4 iter, dvoid **buf
return OCI_ERROR;
}
nested_stmt->parent_stmtid = outcol->statement->id;
- zend_list_addref(outcol->statement->id);
+ ++GC_REFCOUNT(outcol->statement->id);
outcol->nested_statement = nested_stmt;
outcol->stmtid = nested_stmt->id;
@@ -590,7 +590,7 @@ int php_oci_statement_execute(php_oci_statement *statement, ub4 mode TSRMLS_DC)
for (counter = 1; counter <= colcount; counter++) {
memset(&column,0,sizeof(php_oci_out_column));
- if (zend_hash_index_update(statement->columns, counter, &column, sizeof(php_oci_out_column), (void**) &outcol) == FAILURE) {
+ if ((outcol = zend_hash_index_update_ptr(statement->columns, counter, &column)) == NULL) {
efree(statement->columns);
/* out of memory */
return 1;
@@ -683,7 +683,7 @@ int php_oci_statement_execute(php_oci_statement *statement, ub4 mode TSRMLS_DC)
/* find a user-set define */
if (statement->defines) {
- if (zend_hash_find(statement->defines,outcol->name,outcol->name_len,(void **) &outcol->define) == SUCCESS) {
+ if ((outcol->define = zend_hash_str_find_ptr(statement->defines, outcol->name, outcol->name_len)) != NULL) {
if (outcol->define->type) {
outcol->data_type = outcol->define->type;
}
@@ -909,7 +909,7 @@ int php_oci_bind_pre_exec(void *data, void *result TSRMLS_DC)
*(int *)result = 0;
- if (Z_TYPE_P(bind->zval) == IS_ARRAY) {
+ if (Z_TYPE(bind->zval) == IS_ARRAY) {
/* These checks are currently valid for oci_bind_by_name, not
* oci_bind_array_by_name. Also bind->type and
* bind->indicator are not used for oci_bind_array_by_name.
@@ -923,7 +923,7 @@ int php_oci_bind_pre_exec(void *data, void *result TSRMLS_DC)
case SQLT_CLOB:
case SQLT_BLOB:
case SQLT_RDD:
- if (Z_TYPE_P(bind->zval) != IS_OBJECT) {
+ if (Z_TYPE(bind->zval) != IS_OBJECT) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid variable used for bind");
*(int *)result = 1;
}
@@ -939,14 +939,14 @@ int php_oci_bind_pre_exec(void *data, void *result TSRMLS_DC)
case SQLT_LBI:
case SQLT_BIN:
case SQLT_LNG:
- if (Z_TYPE_P(bind->zval) == IS_RESOURCE || Z_TYPE_P(bind->zval) == IS_OBJECT) {
+ if (Z_TYPE(bind->zval) == IS_RESOURCE || Z_TYPE(bind->zval) == IS_OBJECT) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid variable used for bind");
*(int *)result = 1;
}
break;
case SQLT_RSET:
- if (Z_TYPE_P(bind->zval) != IS_RESOURCE) {
+ if (Z_TYPE(bind->zval) != IS_RESOURCE) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid variable used for bind");
*(int *)result = 1;
}
@@ -969,27 +969,27 @@ int php_oci_bind_post_exec(void *data TSRMLS_DC)
sword errstatus;
if (bind->indicator == -1) { /* NULL */
- zval *val = bind->zval;
+ zval *val = &bind->zval;
if (Z_TYPE_P(val) == IS_STRING) {
*Z_STRVAL_P(val) = '\0'; /* XXX avoid warning in debug mode */
}
zval_dtor(val);
ZVAL_NULL(val);
- } else if (Z_TYPE_P(bind->zval) == IS_STRING
- && Z_STRLEN_P(bind->zval) > 0
- && Z_STRVAL_P(bind->zval)[ Z_STRLEN_P(bind->zval) ] != '\0') {
+ } else if (Z_TYPE(bind->zval) == IS_STRING
+ && Z_STRLEN(bind->zval) > 0
+ && Z_STRVAL(bind->zval)[ Z_STRLEN(bind->zval) ] != '\0') {
/* The post- PHP 5.3 feature for "interned" strings disallows
* their reallocation but (i) any IN binds either interned or
* not should already be null terminated and (ii) for OUT
* binds, php_oci_bind_out_callback() should have allocated a
* new string that we can modify here.
*/
- Z_STRVAL_P(bind->zval) = erealloc(Z_STRVAL_P(bind->zval), Z_STRLEN_P(bind->zval)+1);
- Z_STRVAL_P(bind->zval)[ Z_STRLEN_P(bind->zval) ] = '\0';
- } else if (Z_TYPE_P(bind->zval) == IS_ARRAY) {
+ Z_STR(bind->zval) = zend_string_realloc(Z_STR(bind->zval), Z_STRLEN(bind->zval)+1, 0);
+ Z_STRVAL(bind->zval)[ Z_STRLEN(bind->zval) ] = '\0';
+ } else if (Z_TYPE(bind->zval) == IS_ARRAY) {
int i;
- zval **entry;
- HashTable *hash = HASH_OF(bind->zval);
+ zval *entry = NULL;
+ HashTable *hash = HASH_OF(&bind->zval);
zend_hash_internal_pointer_reset(hash);
@@ -998,23 +998,23 @@ int php_oci_bind_post_exec(void *data TSRMLS_DC)
case SQLT_INT:
case SQLT_LNG:
for (i = 0; i < bind->array.current_length; i++) {
- if ((i < bind->array.old_length) && (zend_hash_get_current_data(hash, (void **) &entry) != FAILURE)) {
- zval_dtor(*entry);
- ZVAL_LONG(*entry, ((ub4 *)(bind->array.elements))[i]);
+ if ((i < bind->array.old_length) && (entry = zend_hash_get_current_data(hash)) != NULL) {
+ zval_dtor(entry);
+ ZVAL_LONG(entry, ((ub4 *)(bind->array.elements))[i]);
zend_hash_move_forward(hash);
} else {
- add_next_index_long(bind->zval, ((ub4 *)(bind->array.elements))[i]);
+ add_next_index_long(&bind->zval, ((ub4 *)(bind->array.elements))[i]);
}
}
break;
case SQLT_FLT:
for (i = 0; i < bind->array.current_length; i++) {
- if ((i < bind->array.old_length) && (zend_hash_get_current_data(hash, (void **) &entry) != FAILURE)) {
- zval_dtor(*entry);
- ZVAL_DOUBLE(*entry, ((double *)(bind->array.elements))[i]);
+ if ((i < bind->array.old_length) && (entry = zend_hash_get_current_data(hash)) != NULL) {
+ zval_dtor(entry);
+ ZVAL_DOUBLE(entry, ((double *)(bind->array.elements))[i]);
zend_hash_move_forward(hash);
} else {
- add_next_index_double(bind->zval, ((double *)(bind->array.elements))[i]);
+ add_next_index_double(&bind->zval, ((double *)(bind->array.elements))[i]);
}
}
break;
@@ -1025,17 +1025,17 @@ int php_oci_bind_post_exec(void *data TSRMLS_DC)
memset((void*)buff,0,sizeof(buff));
- if ((i < bind->array.old_length) && (zend_hash_get_current_data(hash, (void **) &entry) != FAILURE)) {
+ if ((i < bind->array.old_length) && (entry = zend_hash_get_current_data(hash)) != NULL) {
PHP_OCI_CALL_RETURN(errstatus, OCIDateToText, (connection->err, &(((OCIDate *)(bind->array.elements))[i]), 0, 0, 0, 0, &buff_len, buff));
- zval_dtor(*entry);
+ zval_dtor(entry);
if (errstatus != OCI_SUCCESS) {
connection->errcode = php_oci_error(connection->err, errstatus TSRMLS_CC);
PHP_OCI_HANDLE_ERROR(connection, connection->errcode);
- ZVAL_NULL(*entry);
+ ZVAL_NULL(entry);
} else {
connection->errcode = 0; /* retain backwards compat with OCI8 1.4 */
- ZVAL_STRINGL(*entry, (char *)buff, buff_len, 1);
+ ZVAL_STRINGL(entry, (char *)buff, buff_len);
}
zend_hash_move_forward(hash);
} else {
@@ -1043,10 +1043,10 @@ int php_oci_bind_post_exec(void *data TSRMLS_DC)
if (errstatus != OCI_SUCCESS) {
connection->errcode = php_oci_error(connection->err, errstatus TSRMLS_CC);
PHP_OCI_HANDLE_ERROR(connection, connection->errcode);
- add_next_index_null(bind->zval);
+ add_next_index_null(&bind->zval);
} else {
connection->errcode = 0; /* retain backwards compat with OCI8 1.4 */
- add_next_index_stringl(bind->zval, (char *)buff, buff_len);
+ add_next_index_stringl(&bind->zval, (char *)buff, buff_len);
}
}
}
@@ -1061,12 +1061,12 @@ int php_oci_bind_post_exec(void *data TSRMLS_DC)
for (i = 0; i < bind->array.current_length; i++) {
/* int curr_element_length = strlen(((text *)bind->array.elements)+i*bind->array.max_length); */
int curr_element_length = bind->array.element_lengths[i];
- if ((i < bind->array.old_length) && (zend_hash_get_current_data(hash, (void **) &entry) != FAILURE)) {
- zval_dtor(*entry);
- ZVAL_STRINGL(*entry, (char *)(((text *)bind->array.elements)+i*bind->array.max_length), curr_element_length, 1);
+ if ((i < bind->array.old_length) && (entry = zend_hash_get_current_data(hash)) != NULL) {
+ zval_dtor(entry);
+ ZVAL_STRINGL(entry, (char *)(((text *)bind->array.elements)+i*bind->array.max_length), curr_element_length);
zend_hash_move_forward(hash);
} else {
- add_next_index_stringl(bind->zval, (char *)(((text *)bind->array.elements)+i*bind->array.max_length), curr_element_length);
+ add_next_index_stringl(&bind->zval, (char *)(((text *)bind->array.elements)+i*bind->array.max_length), curr_element_length);
}
}
break;
@@ -1079,7 +1079,7 @@ int php_oci_bind_post_exec(void *data TSRMLS_DC)
/* {{{ php_oci_bind_by_name()
Bind zval to the given placeholder */
-int php_oci_bind_by_name(php_oci_statement *statement, char *name, int name_len, zval *var, long maxlength, ub2 type TSRMLS_DC)
+int php_oci_bind_by_name(php_oci_statement *statement, char *name, int name_len, zval *var, zend_long maxlength, ub2 type TSRMLS_DC)
{
php_oci_collection *bind_collection = NULL;
php_oci_descriptor *bind_descriptor = NULL;
@@ -1096,14 +1096,14 @@ int php_oci_bind_by_name(php_oci_statement *statement, char *name, int name_len,
switch (type) {
case SQLT_NTY:
{
- zval **tmp;
+ zval *tmp;
- if (Z_TYPE_P(var) != IS_OBJECT || zend_hash_find(Z_OBJPROP_P(var), "collection", sizeof("collection"), (void **)&tmp) == FAILURE) {
+ if (Z_TYPE_P(var) != IS_OBJECT || (tmp = zend_hash_str_find(Z_OBJPROP_P(var), "collection", sizeof("collection"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find collection property");
return 1;
}
- PHP_OCI_ZVAL_TO_COLLECTION_EX(*tmp, bind_collection);
+ PHP_OCI_ZVAL_TO_COLLECTION_EX(tmp, bind_collection);
value_sz = sizeof(void*);
mode = OCI_DEFAULT;
@@ -1118,14 +1118,14 @@ int php_oci_bind_by_name(php_oci_statement *statement, char *name, int name_len,
case SQLT_BLOB:
case SQLT_RDD:
{
- zval **tmp;
+ zval *tmp;
- if (Z_TYPE_P(var) != IS_OBJECT || zend_hash_find(Z_OBJPROP_P(var), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if (Z_TYPE_P(var) != IS_OBJECT || (tmp = zend_hash_str_find(Z_OBJPROP_P(var), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find descriptor property");
return 1;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR_EX(*tmp, bind_descriptor);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR_EX(tmp, bind_descriptor);
value_sz = sizeof(void*);
@@ -1213,21 +1213,19 @@ int php_oci_bind_by_name(php_oci_statement *statement, char *name, int name_len,
}
memset((void*)&bind,0,sizeof(php_oci_bind));
- if (zend_hash_find(statement->binds, name, name_len + 1, (void **)&old_bind) == SUCCESS) {
+ if ((old_bind = zend_hash_str_find_ptr(statement->binds, name, name_len)) != NULL) {
bindp = old_bind;
- if (bindp->zval) {
- zval_ptr_dtor(&bindp->zval);
- }
+ zval_ptr_dtor(&bindp->zval);
} else {
- zend_hash_update(statement->binds, name, name_len + 1, &bind, sizeof(php_oci_bind), (void **)&bindp);
+ bindp = zend_hash_update_ptr(statement->binds, zend_string_init(name, name_len + 1, 0), &bind);
}
bindp->descriptor = oci_desc;
bindp->statement = oci_stmt;
bindp->parent_statement = statement;
- bindp->zval = var;
+ ZVAL_COPY(&bindp->zval, var);
bindp->type = type;
- zval_add_ref(&var);
+ Z_ADDREF_P(var);
PHP_OCI_CALL_RETURN(errstatus,
OCIBindByName,
@@ -1316,7 +1314,7 @@ sb4 php_oci_bind_in_callback(
zval *val;
TSRMLS_FETCH();
- if (!(phpbind=(php_oci_bind *)ictxp) || !(val = phpbind->zval)) {
+ if (!(phpbind=(php_oci_bind *)ictxp) || !(val = &phpbind->zval)) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid phpbind pointer value");
return OCI_ERROR;
}
@@ -1370,7 +1368,7 @@ sb4 php_oci_bind_out_callback(
sb4 retval = OCI_ERROR;
TSRMLS_FETCH();
- if (!(phpbind=(php_oci_bind *)octxp) || !(val = phpbind->zval)) {
+ if (!(phpbind=(php_oci_bind *)octxp) || !(val = &phpbind->zval)) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid phpbind pointer value");
return retval;
}
@@ -1386,7 +1384,7 @@ sb4 php_oci_bind_out_callback(
}
retval = OCI_CONTINUE;
} else if (Z_TYPE_P(val) == IS_OBJECT) {
- zval **tmp;
+ zval *tmp;
php_oci_descriptor *desc;
if (!phpbind->descriptor) {
@@ -1397,11 +1395,11 @@ sb4 php_oci_bind_out_callback(
* out-bind as the contents would have been changed for in/out
* binds (Bug #46994).
*/
- if (zend_hash_find(Z_OBJPROP_P(val), "descriptor", sizeof("descriptor"), (void **)&tmp) == FAILURE) {
+ if ((tmp = zend_hash_str_find(Z_OBJPROP_P(val), "descriptor", sizeof("descriptor"))) == NULL) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unable to find object outbind descriptor property");
return OCI_ERROR;
}
- PHP_OCI_ZVAL_TO_DESCRIPTOR_EX(*tmp, desc);
+ PHP_OCI_ZVAL_TO_DESCRIPTOR_EX(tmp, desc);
desc->lob_size = -1; /* force OCI8 to update cached size */
*alenpp = &phpbind->dummy_len;
@@ -1414,12 +1412,14 @@ sb4 php_oci_bind_out_callback(
convert_to_string(val);
zval_dtor(val);
- Z_STRLEN_P(val) = PHP_OCI_PIECE_SIZE; /* 64K-1 is max XXX */
- Z_STRVAL_P(val) = ecalloc(1, Z_STRLEN_P(phpbind->zval) + 1);
-
+ //Z_STRLEN_P(val) = PHP_OCI_PIECE_SIZE; /* 64K-1 is max XXX */
+ //Z_STRVAL_P(val) = ecalloc(1, Z_STRLEN_P(phpbind->zval) + 1);
+ // XXX is this right?
+ ZVAL_STRINGL(val, NULL, Z_STRLEN(phpbind->zval) + 1);
+
/* XXX we assume that zend-zval len has 4 bytes */
- *alenpp = (ub4*) &Z_STRLEN_P(phpbind->zval);
- *bufpp = Z_STRVAL_P(phpbind->zval);
+ *alenpp = (ub4*) &Z_STRLEN(phpbind->zval);
+ *bufpp = Z_STRVAL(phpbind->zval);
*piecep = OCI_ONE_PIECE;
*rcodepp = &phpbind->retcode;
*indpp = &phpbind->indicator;
@@ -1442,7 +1442,7 @@ php_oci_out_column *php_oci_statement_get_column_helper(INTERNAL_FUNCTION_PARAME
return NULL;
}
- statement = (php_oci_statement *) zend_fetch_resource(&z_statement TSRMLS_CC, -1, "oci8 statement", NULL, 1, le_statement);
+ statement = (php_oci_statement *) zend_fetch_resource(z_statement TSRMLS_CC, -1, "oci8 statement", NULL, 1, le_statement);
if (!statement) {
return NULL;
@@ -1466,7 +1466,7 @@ php_oci_out_column *php_oci_statement_get_column_helper(INTERNAL_FUNCTION_PARAME
convert_to_long(&tmp);
column = php_oci_statement_get_column(statement, Z_LVAL(tmp), NULL, 0 TSRMLS_CC);
if (!column) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid column index \"%ld\"", Z_LVAL(tmp));
+ php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid column index \"%pd\"", Z_LVAL(tmp));
zval_dtor(&tmp);
return NULL;
}
@@ -1524,7 +1524,7 @@ int php_oci_statement_get_numrows(php_oci_statement *statement, ub4 *numrows TSR
/* {{{ php_oci_bind_array_by_name()
Bind arrays to PL/SQL types */
-int php_oci_bind_array_by_name(php_oci_statement *statement, char *name, int name_len, zval *var, long max_table_length, long maxlength, long type TSRMLS_DC)
+int php_oci_bind_array_by_name(php_oci_statement *statement, char *name, int name_len, zval *var, zend_long max_table_length, zend_long maxlength, zend_long type TSRMLS_DC)
{
php_oci_bind *bind, *bindp;
sword errstatus;
@@ -1532,7 +1532,7 @@ int php_oci_bind_array_by_name(php_oci_statement *statement, char *name, int nam
convert_to_array(var);
if (maxlength < -1) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid max length value (%ld)", maxlength);
+ php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid max length value (%pd)", maxlength);
return 1;
}
@@ -1563,7 +1563,7 @@ int php_oci_bind_array_by_name(php_oci_statement *statement, char *name, int nam
bind = php_oci_bind_array_helper_date(var, max_table_length, statement->connection TSRMLS_CC);
break;
default:
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown or unsupported datatype given: %ld", type);
+ php_error_docref(NULL TSRMLS_CC, E_WARNING, "Unknown or unsupported datatype given: %pd", type);
return 1;
break;
}
@@ -1578,18 +1578,18 @@ int php_oci_bind_array_by_name(php_oci_statement *statement, char *name, int nam
zend_hash_init(statement->binds, 13, NULL, php_oci_bind_hash_dtor, 0);
}
- zend_hash_update(statement->binds, name, name_len + 1, bind, sizeof(php_oci_bind), (void **)&bindp);
+ bindp = zend_hash_update_ptr(statement->binds, zend_string_init(name, name_len + 1, 0), bind);
bindp->descriptor = NULL;
bindp->statement = NULL;
bindp->parent_statement = statement;
bindp->bind = NULL;
- bindp->zval = var;
+ ZVAL_COPY(&bindp->zval, var);
bindp->array.type = type;
bindp->indicator = 0; /* not used for array binds */
bindp->type = 0; /* not used for array binds */
- zval_add_ref(&var);
+ Z_ADDREF_P(var);
PHP_OCI_CALL_RETURN(errstatus,
OCIBindByName,
@@ -1626,21 +1626,21 @@ int php_oci_bind_array_by_name(php_oci_statement *statement, char *name, int nam
/* {{{ php_oci_bind_array_helper_string()
Bind arrays to PL/SQL types */
-php_oci_bind *php_oci_bind_array_helper_string(zval *var, long max_table_length, long maxlength TSRMLS_DC)
+php_oci_bind *php_oci_bind_array_helper_string(zval *var, zend_long max_table_length, zend_long maxlength TSRMLS_DC)
{
php_oci_bind *bind;
ub4 i;
HashTable *hash;
- zval **entry;
+ zval *entry;
hash = HASH_OF(var);
if (maxlength == -1) {
zend_hash_internal_pointer_reset(hash);
- while (zend_hash_get_current_data(hash, (void **) &entry) != FAILURE) {
+ while ((entry = zend_hash_get_current_data(hash)) != NULL) {
convert_to_string_ex(entry);
- if (Z_STRLEN_PP(entry) > maxlength) {
- maxlength = Z_STRLEN_PP(entry) + 1;
+ if (Z_STRLEN_P(entry) > maxlength) {
+ maxlength = Z_STRLEN_P(entry) + 1;
}
zend_hash_move_forward(hash);
}
@@ -1660,10 +1660,10 @@ php_oci_bind *php_oci_bind_array_helper_string(zval *var, long max_table_length,
zend_hash_internal_pointer_reset(hash);
for (i = 0; i < bind->array.current_length; i++) {
- if (zend_hash_get_current_data(hash, (void **) &entry) != FAILURE) {
+ if ((entry = zend_hash_get_current_data(hash)) != NULL) {
convert_to_string_ex(entry);
- bind->array.element_lengths[i] = Z_STRLEN_PP(entry);
- if (Z_STRLEN_PP(entry) == 0) {
+ bind->array.element_lengths[i] = Z_STRLEN_P(entry);
+ if (Z_STRLEN_P(entry) == 0) {
bind->array.indicators[i] = -1;
}
zend_hash_move_forward(hash);
@@ -1674,13 +1674,13 @@ php_oci_bind *php_oci_bind_array_helper_string(zval *var, long max_table_length,
zend_hash_internal_pointer_reset(hash);
for (i = 0; i < max_table_length; i++) {
- if ((i < bind->array.current_length) && (zend_hash_get_current_data(hash, (void **) &entry) != FAILURE)) {
+ if ((i < bind->array.current_length) && (entry = zend_hash_get_current_data(hash)) != NULL) {
int element_length;
convert_to_string_ex(entry);
- element_length = (maxlength > Z_STRLEN_PP(entry)) ? Z_STRLEN_PP(entry) : maxlength;
+ element_length = (maxlength > Z_STRLEN_P(entry)) ? Z_STRLEN_P(entry) : maxlength;
- memcpy((text *)bind->array.elements + i*maxlength, Z_STRVAL_PP(entry), element_length);
+ memcpy((text *)bind->array.elements + i*maxlength, Z_STRVAL_P(entry), element_length);
((text *)bind->array.elements)[i*maxlength + element_length] = '\0';
zend_hash_move_forward(hash);
@@ -1696,12 +1696,12 @@ php_oci_bind *php_oci_bind_array_helper_string(zval *var, long max_table_length,
/* {{{ php_oci_bind_array_helper_number()
Bind arrays to PL/SQL types */
-php_oci_bind *php_oci_bind_array_helper_number(zval *var, long max_table_length TSRMLS_DC)
+php_oci_bind *php_oci_bind_array_helper_number(zval *var, zend_long max_table_length TSRMLS_DC)
{
php_oci_bind *bind;
ub4 i;
HashTable *hash;
- zval **entry;
+ zval *entry;
hash = HASH_OF(var);
@@ -1719,9 +1719,9 @@ php_oci_bind *php_oci_bind_array_helper_number(zval *var, long max_table_length
if (i < bind->array.current_length) {
bind->array.element_lengths[i] = sizeof(ub4);
}
- if ((i < bind->array.current_length) && (zend_hash_get_current_data(hash, (void **) &entry) != FAILURE)) {
+ if ((i < bind->array.current_length) && (entry = zend_hash_get_current_data(hash)) != NULL) {
convert_to_long_ex(entry);
- ((ub4 *)bind->array.elements)[i] = (ub4) Z_LVAL_PP(entry);
+ ((ub4 *)bind->array.elements)[i] = (ub4) Z_LVAL_P(entry);
zend_hash_move_forward(hash);
} else {
((ub4 *)bind->array.elements)[i] = 0;
@@ -1735,12 +1735,12 @@ php_oci_bind *php_oci_bind_array_helper_number(zval *var, long max_table_length
/* {{{ php_oci_bind_array_helper_double()
Bind arrays to PL/SQL types */
-php_oci_bind *php_oci_bind_array_helper_double(zval *var, long max_table_length TSRMLS_DC)
+php_oci_bind *php_oci_bind_array_helper_double(zval *var, zend_long max_table_length TSRMLS_DC)
{
php_oci_bind *bind;
ub4 i;
HashTable *hash;
- zval **entry;
+ zval *entry;
hash = HASH_OF(var);
@@ -1758,9 +1758,9 @@ php_oci_bind *php_oci_bind_array_helper_double(zval *var, long max_table_length
if (i < bind->array.current_length) {
bind->array.element_lengths[i] = sizeof(double);
}
- if ((i < bind->array.current_length) && (zend_hash_get_current_data(hash, (void **) &entry) != FAILURE)) {
+ if ((i < bind->array.current_length) && (entry = zend_hash_get_current_data(hash)) != NULL) {
convert_to_double_ex(entry);
- ((double *)bind->array.elements)[i] = (double) Z_DVAL_PP(entry);
+ ((double *)bind->array.elements)[i] = (double) Z_DVAL_P(entry);
zend_hash_move_forward(hash);
} else {
((double *)bind->array.elements)[i] = 0;
@@ -1774,12 +1774,12 @@ php_oci_bind *php_oci_bind_array_helper_double(zval *var, long max_table_length
/* {{{ php_oci_bind_array_helper_date()
Bind arrays to PL/SQL types */
-php_oci_bind *php_oci_bind_array_helper_date(zval *var, long max_table_length, php_oci_connection *connection TSRMLS_DC)
+php_oci_bind *php_oci_bind_array_helper_date(zval *var, zend_long max_table_length, php_oci_connection *connection TSRMLS_DC)
{
php_oci_bind *bind;
ub4 i;
HashTable *hash;
- zval **entry;
+ zval *entry;
sword errstatus;
hash = HASH_OF(var);
@@ -1799,10 +1799,10 @@ php_oci_bind *php_oci_bind_array_helper_date(zval *var, long max_table_length, p
if (i < bind->array.current_length) {
bind->array.element_lengths[i] = sizeof(OCIDate);
}
- if ((i < bind->array.current_length) && (zend_hash_get_current_data(hash, (void **) &entry) != FAILURE)) {
+ if ((i < bind->array.current_length) && (entry = zend_hash_get_current_data(hash)) != NULL) {
convert_to_string_ex(entry);
- PHP_OCI_CALL_RETURN(errstatus, OCIDateFromText, (connection->err, (CONST text *)Z_STRVAL_PP(entry), Z_STRLEN_PP(entry), NULL, 0, NULL, 0, &oci_date));
+ PHP_OCI_CALL_RETURN(errstatus, OCIDateFromText, (connection->err, (CONST text *)Z_STRVAL_P(entry), Z_STRLEN_P(entry), NULL, 0, NULL, 0, &oci_date));
if (errstatus != OCI_SUCCESS) {
/* failed to convert string to date */
diff --git a/ext/oci8/php_oci8.h b/ext/oci8/php_oci8.h
index 066812edad..d673a3c083 100644
--- a/ext/oci8/php_oci8.h
+++ b/ext/oci8/php_oci8.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/oci8/php_oci8_int.h b/ext/oci8/php_oci8_int.h
index 7cf3d170fa..852fe986f3 100644
--- a/ext/oci8/php_oci8_int.h
+++ b/ext/oci8/php_oci8_int.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -144,7 +144,7 @@ typedef struct {
sb4 errcode; /* last ORA- error number */
HashTable *descriptors; /* descriptors hash, used to flush all the LOBs using this connection on commit */
- ulong descriptor_count; /* used to index the descriptors hash table. Not an accurate count */
+ zend_ulong descriptor_count; /* used to index the descriptors hash table. Not an accurate count */
unsigned is_open:1; /* hels to determine if the connection is dead or not */
unsigned is_attached:1; /* hels to determine if we should detach from the server when closing/freeing the connection */
unsigned is_persistent:1; /* self-descriptive */
@@ -165,7 +165,7 @@ typedef struct {
/* {{{ php_oci_descriptor */
typedef struct {
zend_resource *id;
- ulong index; /* descriptors hash table index */
+ zend_ulong index; /* descriptors hash table index */
php_oci_connection *connection; /* parent connection handle */
dvoid *descriptor; /* OCI descriptor handle */
ub4 type; /* descriptor type (FILE/LOB) */
@@ -221,7 +221,7 @@ typedef struct {
OCIStmt *stmt; /* statement handle */
char *last_query; /* last query issued. also used to determine if this is a statement or a refcursor received from Oracle */
char impres_flag; /* PHP_OCI_IMPRES_*_ */
- long last_query_len; /* last query length */
+ zend_long last_query_len; /* last query length */
HashTable *columns; /* hash containing all the result columns */
HashTable *binds; /* binds hash */
HashTable *defines; /* defines hash */
@@ -249,7 +249,7 @@ typedef struct {
ub4 current_length;
ub4 old_length;
ub4 max_length;
- long type;
+ zend_long type;
} array;
sb2 indicator; /* -1 means NULL */
ub2 retcode;
@@ -361,20 +361,20 @@ typedef struct {
} while (0)
#define PHP_OCI_ZVAL_TO_CONNECTION(zval, connection) \
- ZEND_FETCH_RESOURCE2(connection, php_oci_connection *, &zval, -1, "oci8 connection", le_connection, le_pconnection)
+ ZEND_FETCH_RESOURCE2(connection, php_oci_connection *, zval, -1, "oci8 connection", le_connection, le_pconnection)
#define PHP_OCI_ZVAL_TO_STATEMENT(zval, statement) \
ZEND_FETCH_RESOURCE(statement, php_oci_statement *, zval, -1, "oci8 statement", le_statement)
#define PHP_OCI_ZVAL_TO_DESCRIPTOR(zval, descriptor) \
- ZEND_FETCH_RESOURCE(descriptor, php_oci_descriptor *, &zval, -1, "oci8 descriptor", le_descriptor)
+ ZEND_FETCH_RESOURCE(descriptor, php_oci_descriptor *, zval, -1, "oci8 descriptor", le_descriptor)
#define PHP_OCI_ZVAL_TO_COLLECTION(zval, collection) \
- ZEND_FETCH_RESOURCE(collection, php_oci_collection *, &zval, -1, "oci8 collection", le_collection)
+ ZEND_FETCH_RESOURCE(collection, php_oci_collection *, zval, -1, "oci8 collection", le_collection)
#define PHP_OCI_FETCH_RESOURCE_EX(zval, var, type, name, resource_type) \
do { \
- var = (type) zend_fetch_resource(&zval TSRMLS_CC, -1, name, NULL, 1, resource_type); \
+ var = (type) zend_fetch_resource(zval TSRMLS_CC, -1, name, NULL, 1, resource_type); \
if (!var) { \
return 1; \
} \
@@ -407,7 +407,7 @@ sb4 php_oci_error(OCIError *err_p, sword status TSRMLS_DC);
sb4 php_oci_fetch_errmsg(OCIError *error_handle, text **error_buf TSRMLS_DC);
int php_oci_fetch_sqltext_offset(php_oci_statement *statement, text **sqltext, ub2 *error_offset TSRMLS_DC);
void php_oci_do_connect(INTERNAL_FUNCTION_PARAMETERS, int persistent, int exclusive);
-php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char *password, int password_len, char *new_password, int new_password_len, char *dbname, int dbname_len, char *charset, long session_mode, int persistent, int exclusive TSRMLS_DC);
+php_oci_connection *php_oci_do_connect_ex(char *username, int username_len, char *password, int password_len, char *new_password, int new_password_len, char *dbname, int dbname_len, char *charset, zend_long session_mode, int persistent, int exclusive TSRMLS_DC);
int php_oci_connection_rollback(php_oci_connection *connection TSRMLS_DC);
int php_oci_connection_commit(php_oci_connection *connection TSRMLS_DC);
int php_oci_connection_release(php_oci_connection *connection TSRMLS_DC);
@@ -422,22 +422,22 @@ void php_oci_dtrace_check_connection(php_oci_connection *connection, sb4 errcode
/* {{{ lob related prototypes */
-php_oci_descriptor *php_oci_lob_create(php_oci_connection *connection, long type TSRMLS_DC);
+php_oci_descriptor *php_oci_lob_create(php_oci_connection *connection, zend_long type TSRMLS_DC);
int php_oci_lob_get_length(php_oci_descriptor *descriptor, ub4 *length TSRMLS_DC);
-int php_oci_lob_read(php_oci_descriptor *descriptor, long read_length, long inital_offset, char **data, ub4 *data_len TSRMLS_DC);
+int php_oci_lob_read(php_oci_descriptor *descriptor, zend_long read_length, zend_long inital_offset, char **data, ub4 *data_len TSRMLS_DC);
int php_oci_lob_write(php_oci_descriptor *descriptor, ub4 offset, char *data, int data_len, ub4 *bytes_written TSRMLS_DC);
-int php_oci_lob_flush(php_oci_descriptor *descriptor, long flush_flag TSRMLS_DC);
+int php_oci_lob_flush(php_oci_descriptor *descriptor, zend_long flush_flag TSRMLS_DC);
int php_oci_lob_set_buffering(php_oci_descriptor *descriptor, int on_off TSRMLS_DC);
int php_oci_lob_get_buffering(php_oci_descriptor *descriptor);
-int php_oci_lob_copy(php_oci_descriptor *descriptor, php_oci_descriptor *descriptor_from, long length TSRMLS_DC);
+int php_oci_lob_copy(php_oci_descriptor *descriptor, php_oci_descriptor *descriptor_from, zend_long length TSRMLS_DC);
int php_oci_lob_close(php_oci_descriptor *descriptor TSRMLS_DC);
int php_oci_temp_lob_close(php_oci_descriptor *descriptor TSRMLS_DC);
-int php_oci_lob_write_tmp(php_oci_descriptor *descriptor, long type, char *data, int data_len TSRMLS_DC);
+int php_oci_lob_write_tmp(php_oci_descriptor *descriptor, zend_long type, char *data, int data_len TSRMLS_DC);
void php_oci_lob_free(php_oci_descriptor *descriptor TSRMLS_DC);
int php_oci_lob_import(php_oci_descriptor *descriptor, char *filename TSRMLS_DC);
int php_oci_lob_append(php_oci_descriptor *descriptor_dest, php_oci_descriptor *descriptor_from TSRMLS_DC);
-int php_oci_lob_truncate(php_oci_descriptor *descriptor, long new_lob_length TSRMLS_DC);
-int php_oci_lob_erase(php_oci_descriptor *descriptor, long offset, ub4 length, ub4 *bytes_erased TSRMLS_DC);
+int php_oci_lob_truncate(php_oci_descriptor *descriptor, zend_long new_lob_length TSRMLS_DC);
+int php_oci_lob_erase(php_oci_descriptor *descriptor, zend_long offset, ub4 length, ub4 *bytes_erased TSRMLS_DC);
int php_oci_lob_is_equal(php_oci_descriptor *descriptor_first, php_oci_descriptor *descriptor_second, boolean *result TSRMLS_DC);
sb4 php_oci_lob_callback(dvoid *ctxp, CONST dvoid *bufxp, oraub8 len, ub1 piece, dvoid **changed_bufpp, oraub8 *changed_lenp);
/* }}} */
@@ -446,15 +446,15 @@ sb4 php_oci_lob_callback(dvoid *ctxp, CONST dvoid *bufxp, oraub8 len, ub1 piece,
php_oci_collection *php_oci_collection_create(php_oci_connection *connection, char *tdo, int tdo_len, char *schema, int schema_len TSRMLS_DC);
int php_oci_collection_size(php_oci_collection *collection, sb4 *size TSRMLS_DC);
-int php_oci_collection_max(php_oci_collection *collection, long *max TSRMLS_DC);
-int php_oci_collection_trim(php_oci_collection *collection, long trim_size TSRMLS_DC);
+int php_oci_collection_max(php_oci_collection *collection, zend_long *max TSRMLS_DC);
+int php_oci_collection_trim(php_oci_collection *collection, zend_long trim_size TSRMLS_DC);
int php_oci_collection_append(php_oci_collection *collection, char *element, int element_len TSRMLS_DC);
-int php_oci_collection_element_get(php_oci_collection *collection, long index, zval **result_element TSRMLS_DC);
-int php_oci_collection_element_set(php_oci_collection *collection, long index, char *value, int value_len TSRMLS_DC);
-int php_oci_collection_element_set_null(php_oci_collection *collection, long index TSRMLS_DC);
-int php_oci_collection_element_set_date(php_oci_collection *collection, long index, char *date, int date_len TSRMLS_DC);
-int php_oci_collection_element_set_number(php_oci_collection *collection, long index, char *number, int number_len TSRMLS_DC);
-int php_oci_collection_element_set_string(php_oci_collection *collection, long index, char *element, int element_len TSRMLS_DC);
+int php_oci_collection_element_get(php_oci_collection *collection, zend_long index, zval *result_element TSRMLS_DC);
+int php_oci_collection_element_set(php_oci_collection *collection, zend_long index, char *value, int value_len TSRMLS_DC);
+int php_oci_collection_element_set_null(php_oci_collection *collection, zend_long index TSRMLS_DC);
+int php_oci_collection_element_set_date(php_oci_collection *collection, zend_long index, char *date, int date_len TSRMLS_DC);
+int php_oci_collection_element_set_number(php_oci_collection *collection, zend_long index, char *number, int number_len TSRMLS_DC);
+int php_oci_collection_element_set_string(php_oci_collection *collection, zend_long index, char *element, int element_len TSRMLS_DC);
int php_oci_collection_assign(php_oci_collection *collection_dest, php_oci_collection *collection_from TSRMLS_DC);
void php_oci_collection_close(php_oci_collection *collection TSRMLS_DC);
int php_oci_collection_append_null(php_oci_collection *collection TSRMLS_DC);
@@ -471,24 +471,24 @@ php_oci_statement *php_oci_statement_create(php_oci_connection *connection, char
php_oci_statement *php_oci_get_implicit_resultset(php_oci_statement *statement TSRMLS_DC);
int php_oci_statement_set_prefetch(php_oci_statement *statement, ub4 prefetch TSRMLS_DC);
int php_oci_statement_fetch(php_oci_statement *statement, ub4 nrows TSRMLS_DC);
-php_oci_out_column *php_oci_statement_get_column(php_oci_statement *statement, long column_index, char *column_name, int column_name_len TSRMLS_DC);
+php_oci_out_column *php_oci_statement_get_column(php_oci_statement *statement, zend_long column_index, char *column_name, int column_name_len TSRMLS_DC);
int php_oci_statement_execute(php_oci_statement *statement, ub4 mode TSRMLS_DC);
int php_oci_statement_cancel(php_oci_statement *statement TSRMLS_DC);
void php_oci_statement_free(php_oci_statement *statement TSRMLS_DC);
int php_oci_bind_pre_exec(void *data, void *result TSRMLS_DC);
int php_oci_bind_post_exec(void *data TSRMLS_DC);
-int php_oci_bind_by_name(php_oci_statement *statement, char *name, int name_len, zval *var, long maxlength, ub2 type TSRMLS_DC);
+int php_oci_bind_by_name(php_oci_statement *statement, char *name, int name_len, zval *var, zend_long maxlength, ub2 type TSRMLS_DC);
sb4 php_oci_bind_in_callback(dvoid *ictxp, OCIBind *bindp, ub4 iter, ub4 index, dvoid **bufpp, ub4 *alenp, ub1 *piecep, dvoid **indpp);
sb4 php_oci_bind_out_callback(dvoid *octxp, OCIBind *bindp, ub4 iter, ub4 index, dvoid **bufpp, ub4 **alenpp, ub1 *piecep, dvoid **indpp, ub2 **rcodepp);
php_oci_out_column *php_oci_statement_get_column_helper(INTERNAL_FUNCTION_PARAMETERS, int need_data);
int php_oci_cleanup_pre_fetch(void *data TSRMLS_DC);
int php_oci_statement_get_type(php_oci_statement *statement, ub2 *type TSRMLS_DC);
int php_oci_statement_get_numrows(php_oci_statement *statement, ub4 *numrows TSRMLS_DC);
-int php_oci_bind_array_by_name(php_oci_statement *statement, char *name, int name_len, zval *var, long max_table_length, long maxlength, long type TSRMLS_DC);
-php_oci_bind *php_oci_bind_array_helper_number(zval *var, long max_table_length TSRMLS_DC);
-php_oci_bind *php_oci_bind_array_helper_double(zval *var, long max_table_length TSRMLS_DC);
-php_oci_bind *php_oci_bind_array_helper_string(zval *var, long max_table_length, long maxlength TSRMLS_DC);
-php_oci_bind *php_oci_bind_array_helper_date(zval *var, long max_table_length, php_oci_connection *connection TSRMLS_DC);
+int php_oci_bind_array_by_name(php_oci_statement *statement, char *name, int name_len, zval *var, zend_long max_table_length, zend_long maxlength, zend_long type TSRMLS_DC);
+php_oci_bind *php_oci_bind_array_helper_number(zval *var, zend_long max_table_length TSRMLS_DC);
+php_oci_bind *php_oci_bind_array_helper_double(zval *var, zend_long max_table_length TSRMLS_DC);
+php_oci_bind *php_oci_bind_array_helper_string(zval *var, zend_long max_table_length, zend_long maxlength TSRMLS_DC);
+php_oci_bind *php_oci_bind_array_helper_date(zval *var, zend_long max_table_length, php_oci_connection *connection TSRMLS_DC);
/* }}} */
@@ -496,14 +496,14 @@ ZEND_BEGIN_MODULE_GLOBALS(oci) /* {{{ Module globals */
sb4 errcode; /* global last ORA- error number. Used when connect fails, for example */
OCIError *err; /* global error handle */
- long max_persistent; /* maximum number of persistent connections per process */
- long num_persistent; /* number of existing persistent connections */
- long num_links; /* non-persistent + persistent connections */
- long num_statements; /* number of statements open */
- long ping_interval; /* time interval between pings */
- long persistent_timeout; /* time period after which idle persistent connection is considered expired */
- long statement_cache_size; /* statement cache size. used with 9i+ clients only*/
- long default_prefetch; /* default prefetch setting */
+ zend_long max_persistent; /* maximum number of persistent connections per process */
+ zend_long num_persistent; /* number of existing persistent connections */
+ zend_long num_links; /* non-persistent + persistent connections */
+ zend_long num_statements; /* number of statements open */
+ zend_long ping_interval; /* time interval between pings */
+ zend_long persistent_timeout; /* time period after which idle persistent connection is considered expired */
+ zend_long statement_cache_size; /* statement cache size. used with 9i+ clients only*/
+ zend_long default_prefetch; /* default prefetch setting */
zend_bool privileged_connect; /* privileged connect flag (On/Off) */
zend_bool old_oci_close_semantics; /* old_oci_close_semantics flag (to determine the way oci_close() should behave) */
diff --git a/ext/odbc/birdstep.c b/ext/odbc/birdstep.c
index 09162ae61b..3857c6955c 100644
--- a/ext/odbc/birdstep.c
+++ b/ext/odbc/birdstep.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/odbc/php_birdstep.h b/ext/odbc/php_birdstep.h
index eb694577fb..eab1dcee7c 100644
--- a/ext/odbc/php_birdstep.h
+++ b/ext/odbc/php_birdstep.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/odbc/php_odbc.c b/ext/odbc/php_odbc.c
index 02af2d94ca..13bd9e1628 100644
--- a/ext/odbc/php_odbc.c
+++ b/ext/odbc/php_odbc.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -2615,13 +2615,13 @@ try_and_get_another_connection:
zend_resource *index_ptr, new_index_ptr;
if ((index_ptr = zend_hash_str_find_ptr(&EG(regular_list), hashed_details, hashed_len)) != NULL) {
- int conn_id;
+ zend_ulong conn_id;
zend_resource *p;
if (index_ptr->type != le_index_ptr) {
RETURN_FALSE;
}
- conn_id = (int)index_ptr->ptr;
+ conn_id = (zend_ulong)index_ptr->ptr;
p = zend_hash_index_find_ptr(&EG(regular_list), conn_id); /* check if the connection is still there */
if (p && p->ptr && (p->type == le_conn || p->type == le_pconn)) {
diff --git a/ext/odbc/php_odbc.h b/ext/odbc/php_odbc.h
index bd78e88f52..9219fa87ad 100644
--- a/ext/odbc/php_odbc.h
+++ b/ext/odbc/php_odbc.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/odbc/php_odbc_includes.h b/ext/odbc/php_odbc_includes.h
index f44b897b9b..6a7e5c3756 100644
--- a/ext/odbc/php_odbc_includes.h
+++ b/ext/odbc/php_odbc_includes.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/opcache/Optimizer/block_pass.c b/ext/opcache/Optimizer/block_pass.c
index 3289299ce1..869bd3ccba 100644
--- a/ext/opcache/Optimizer/block_pass.c
+++ b/ext/opcache/Optimizer/block_pass.c
@@ -169,7 +169,7 @@ static int find_code_blocks(zend_op_array *op_array, zend_cfg *cfg, zend_optimiz
case ZEND_FE_RESET:
case ZEND_NEW:
case ZEND_JMP_SET:
- case ZEND_JMP_SET_VAR:
+ case ZEND_COALESCE:
START_BLOCK_OP(ZEND_OP2(opline).opline_num);
START_BLOCK_OP(opno + 1);
break;
@@ -204,14 +204,12 @@ static int find_code_blocks(zend_op_array *op_array, zend_cfg *cfg, zend_optimiz
j = 0;
for (i = 0; i< op_array->last_brk_cont; i++) {
if (op_array->brk_cont_array[i].start >= 0 &&
- (op_array->opcodes[op_array->brk_cont_array[i].brk].opcode == ZEND_FREE ||
- op_array->opcodes[op_array->brk_cont_array[i].brk].opcode == ZEND_SWITCH_FREE)) {
+ op_array->opcodes[op_array->brk_cont_array[i].brk].opcode == ZEND_FREE) {
int parent = op_array->brk_cont_array[i].parent;
while (parent >= 0 &&
op_array->brk_cont_array[parent].start < 0 &&
- op_array->opcodes[op_array->brk_cont_array[parent].brk].opcode != ZEND_FREE &&
- op_array->opcodes[op_array->brk_cont_array[parent].brk].opcode != ZEND_SWITCH_FREE) {
+ op_array->opcodes[op_array->brk_cont_array[parent].brk].opcode != ZEND_FREE) {
parent = op_array->brk_cont_array[parent].parent;
}
op_array->brk_cont_array[i].parent = parent;
@@ -225,8 +223,7 @@ static int find_code_blocks(zend_op_array *op_array, zend_cfg *cfg, zend_optimiz
j = 0;
for (i = 0; i< op_array->last_brk_cont; i++) {
if (op_array->brk_cont_array[i].start >= 0 &&
- (op_array->opcodes[op_array->brk_cont_array[i].brk].opcode == ZEND_FREE ||
- op_array->opcodes[op_array->brk_cont_array[i].brk].opcode == ZEND_SWITCH_FREE)) {
+ op_array->opcodes[op_array->brk_cont_array[i].brk].opcode == ZEND_FREE) {
if (i != j) {
op_array->brk_cont_array[j] = op_array->brk_cont_array[i];
}
@@ -297,7 +294,7 @@ static int find_code_blocks(zend_op_array *op_array, zend_cfg *cfg, zend_optimiz
case ZEND_FE_RESET:
case ZEND_NEW:
case ZEND_JMP_SET:
- case ZEND_JMP_SET_VAR:
+ case ZEND_COALESCE:
case ZEND_FE_FETCH:
cur_block->op2_to = &blocks[ZEND_OP2(opline).opline_num];
/* break missing intentionally */
@@ -614,7 +611,7 @@ static void zend_optimize_block(zend_code_block *block, zend_op_array *op_array,
end = opline + block->len;
while ((op_array->T) && (opline < end)) {
/* strip X = QM_ASSIGN(const) */
- if (ZEND_OP1_TYPE(opline) == IS_TMP_VAR &&
+ if ((ZEND_OP1_TYPE(opline) & (IS_TMP_VAR|IS_VAR)) &&
VAR_SOURCE(opline->op1) &&
VAR_SOURCE(opline->op1)->opcode == ZEND_QM_ASSIGN &&
ZEND_OP1_TYPE(VAR_SOURCE(opline->op1)) == IS_CONST &&
@@ -633,7 +630,7 @@ static void zend_optimize_block(zend_code_block *block, zend_op_array *op_array,
}
/* T = QM_ASSIGN(C), F(T) => NOP, F(C) */
- if (ZEND_OP2_TYPE(opline) == IS_TMP_VAR &&
+ if ((ZEND_OP2_TYPE(opline) & (IS_TMP_VAR|IS_VAR)) &&
VAR_SOURCE(opline->op2) &&
VAR_SOURCE(opline->op2)->opcode == ZEND_QM_ASSIGN &&
ZEND_OP1_TYPE(VAR_SOURCE(opline->op2)) == IS_CONST) {
@@ -880,10 +877,10 @@ static void zend_optimize_block(zend_code_block *block, zend_op_array *op_array,
opline->opcode == ZEND_JMPNZ_EX ||
opline->opcode == ZEND_JMPNZ ||
opline->opcode == ZEND_JMPZNZ) &&
- ZEND_OP1_TYPE(opline) == IS_TMP_VAR &&
+ (ZEND_OP1_TYPE(opline) & (IS_TMP_VAR|IS_VAR)) &&
VAR_SOURCE(opline->op1) != NULL &&
(!used_ext[VAR_NUM(ZEND_OP1(opline).var)] ||
- (ZEND_RESULT_TYPE(opline) == IS_TMP_VAR &&
+ ((ZEND_RESULT_TYPE(opline) & (IS_TMP_VAR|IS_VAR)) &&
ZEND_RESULT(opline).var == ZEND_OP1(opline).var)) &&
(VAR_SOURCE(opline->op1)->opcode == ZEND_BOOL ||
VAR_SOURCE(opline->op1)->opcode == ZEND_QM_ASSIGN)) {
@@ -913,7 +910,7 @@ static void zend_optimize_block(zend_code_block *block, zend_op_array *op_array,
}
old_len = Z_STRLEN(ZEND_OP1_LITERAL(last_op));
l = old_len + Z_STRLEN(ZEND_OP1_LITERAL(opline));
- if (IS_INTERNED(Z_STR(ZEND_OP1_LITERAL(last_op)))) {
+ if (!Z_REFCOUNTED(ZEND_OP1_LITERAL(last_op))) {
zend_string *tmp = zend_string_alloc(l, 0);
memcpy(tmp->val, Z_STRVAL(ZEND_OP1_LITERAL(last_op)), old_len);
Z_STR(ZEND_OP1_LITERAL(last_op)) = tmp;
@@ -925,7 +922,7 @@ static void zend_optimize_block(zend_code_block *block, zend_op_array *op_array,
Z_STRVAL(ZEND_OP1_LITERAL(last_op))[l] = '\0';
zval_dtor(&ZEND_OP1_LITERAL(opline));
Z_STR(ZEND_OP1_LITERAL(opline)) = zend_new_interned_string(Z_STR(ZEND_OP1_LITERAL(last_op)) TSRMLS_CC);
- if (IS_INTERNED(Z_STR(ZEND_OP1_LITERAL(opline)))) {
+ if (!Z_REFCOUNTED(ZEND_OP1_LITERAL(opline))) {
Z_TYPE_FLAGS(ZEND_OP1_LITERAL(opline)) &= ~ (IS_TYPE_REFCOUNTED | IS_TYPE_COPYABLE);
}
ZVAL_NULL(&ZEND_OP1_LITERAL(last_op));
@@ -957,7 +954,7 @@ static void zend_optimize_block(zend_code_block *block, zend_op_array *op_array,
COPY_NODE(opline->op1, src->op1);
old_len = Z_STRLEN(ZEND_OP2_LITERAL(src));
l = old_len + Z_STRLEN(ZEND_OP2_LITERAL(opline));
- if (IS_INTERNED(Z_STR(ZEND_OP2_LITERAL(src)))) {
+ if (!Z_REFCOUNTED(ZEND_OP2_LITERAL(src))) {
zend_string *tmp = zend_string_alloc(l, 0);
memcpy(tmp->val, Z_STRVAL(ZEND_OP2_LITERAL(src)), old_len);
Z_STR(ZEND_OP2_LITERAL(last_op)) = tmp;
@@ -969,7 +966,7 @@ static void zend_optimize_block(zend_code_block *block, zend_op_array *op_array,
Z_STRVAL(ZEND_OP2_LITERAL(src))[l] = '\0';
zend_string_release(Z_STR(ZEND_OP2_LITERAL(opline)));
Z_STR(ZEND_OP2_LITERAL(opline)) = zend_new_interned_string(Z_STR(ZEND_OP2_LITERAL(src)) TSRMLS_CC);
- if (IS_INTERNED(Z_STR(ZEND_OP2_LITERAL(opline)))) {
+ if (!Z_REFCOUNTED(ZEND_OP2_LITERAL(opline))) {
Z_TYPE_FLAGS(ZEND_OP2_LITERAL(opline)) &= ~ (IS_TYPE_REFCOUNTED | IS_TYPE_COPYABLE);
}
ZVAL_NULL(&ZEND_OP2_LITERAL(src));
@@ -1049,7 +1046,7 @@ static void zend_optimize_block(zend_code_block *block, zend_op_array *op_array,
opline->opcode = ZEND_QM_ASSIGN;
zend_optimizer_update_op1_const(op_array, opline, &result TSRMLS_CC);
} else if ((opline->opcode == ZEND_RETURN || opline->opcode == ZEND_EXIT) &&
- ZEND_OP1_TYPE(opline) == IS_TMP_VAR &&
+ (ZEND_OP1_TYPE(opline) & (IS_TMP_VAR|IS_VAR)) &&
VAR_SOURCE(opline->op1) &&
VAR_SOURCE(opline->op1)->opcode == ZEND_QM_ASSIGN) {
/* T = QM_ASSIGN(X), RETURN(T) to RETURN(X) */
@@ -1058,25 +1055,6 @@ static void zend_optimize_block(zend_code_block *block, zend_op_array *op_array,
COPY_NODE(opline->op1, src->op1);
MAKE_NOP(src);
} else if ((opline->opcode == ZEND_ADD_STRING ||
- opline->opcode == ZEND_ADD_CHAR) &&
- ZEND_OP1_TYPE(opline) == IS_TMP_VAR &&
- VAR_SOURCE(opline->op1) &&
- VAR_SOURCE(opline->op1)->opcode == ZEND_INIT_STRING) {
- /* convert T = INIT_STRING(), T = ADD_STRING(T, X) to T = QM_ASSIGN(X) */
- /* CHECKME: Remove ZEND_ADD_VAR optimization, since some conversions -
- namely, BOOL(false)->string - don't allocate memory but use empty_string
- and ADD_CHAR fails */
- zend_op *src = VAR_SOURCE(opline->op1);
- VAR_UNSET(opline->op1);
- COPY_NODE(opline->op1, opline->op2);
- if (opline->opcode == ZEND_ADD_CHAR) {
- char c = (char)Z_LVAL(ZEND_OP2_LITERAL(opline));
- ZVAL_STRINGL(&ZEND_OP1_LITERAL(opline), &c, 1);
- }
- SET_UNUSED(opline->op2);
- MAKE_NOP(src);
- opline->opcode = ZEND_QM_ASSIGN;
- } else if ((opline->opcode == ZEND_ADD_STRING ||
opline->opcode == ZEND_ADD_CHAR ||
opline->opcode == ZEND_ADD_VAR ||
opline->opcode == ZEND_CONCAT) &&
@@ -1097,28 +1075,11 @@ static void zend_optimize_block(zend_code_block *block, zend_op_array *op_array,
opline->opcode = ZEND_CONCAT;
literal_dtor(&ZEND_OP2_LITERAL(src)); /* will take care of empty_string too */
MAKE_NOP(src);
-//??? This optimization can't work anymore because ADD_VAR returns IS_TMP_VAR
-//??? and ZEND_CAST returns IS_VAR.
-//??? BTW: it wan't used for long time, because we don't use INIT_STRING
-#if 0
- } else if (opline->opcode == ZEND_ADD_VAR &&
- ZEND_OP1_TYPE(opline) == IS_TMP_VAR &&
- VAR_SOURCE(opline->op1) &&
- VAR_SOURCE(opline->op1)->opcode == ZEND_INIT_STRING) {
- /* convert T = INIT_STRING(), T = ADD_VAR(T, X) to T = CAST(STRING, X) */
- zend_op *src = VAR_SOURCE(opline->op1);
- VAR_UNSET(opline->op1);
- COPY_NODE(opline->op1, opline->op2);
- SET_UNUSED(opline->op2);
- MAKE_NOP(src);
- opline->opcode = ZEND_CAST;
- opline->extended_value = IS_STRING;
-#endif
} else if ((opline->opcode == ZEND_ADD_STRING ||
opline->opcode == ZEND_ADD_CHAR ||
opline->opcode == ZEND_ADD_VAR ||
opline->opcode == ZEND_CONCAT) &&
- ZEND_OP1_TYPE(opline) == (IS_TMP_VAR|IS_VAR) &&
+ (ZEND_OP1_TYPE(opline) & (IS_TMP_VAR|IS_VAR)) &&
VAR_SOURCE(opline->op1) &&
VAR_SOURCE(opline->op1)->opcode == ZEND_CAST &&
VAR_SOURCE(opline->op1)->extended_value == IS_STRING) {
@@ -1133,8 +1094,7 @@ static void zend_optimize_block(zend_code_block *block, zend_op_array *op_array,
opline->opcode = ZEND_CONCAT;
MAKE_NOP(src);
} else if (opline->opcode == ZEND_QM_ASSIGN &&
- ZEND_OP1_TYPE(opline) == IS_TMP_VAR &&
- ZEND_RESULT_TYPE(opline) == IS_TMP_VAR &&
+ ZEND_OP1_TYPE(opline) == ZEND_RESULT_TYPE(opline) &&
ZEND_OP1(opline).var == ZEND_RESULT(opline).var) {
/* strip T = QM_ASSIGN(T) */
MAKE_NOP(opline);
@@ -1366,10 +1326,9 @@ static void zend_jmp_optimization(zend_code_block *block, zend_op_array *op_arra
} else if (0&& block->op1_to != block &&
block->op1_to != blocks &&
op_array->last_try_catch == 0 &&
- target->opcode != ZEND_FREE &&
- target->opcode != ZEND_SWITCH_FREE) {
+ target->opcode != ZEND_FREE) {
/* Block Reordering (saves one JMP on each "for" loop iteration)
- * It is disabled for some cases (ZEND_FREE/ZEND_SWITCH_FREE)
+ * It is disabled for some cases (ZEND_FREE)
* which may break register allocation.
*/
zend_bool can_reorder = 0;
diff --git a/ext/opcache/Optimizer/compact_literals.c b/ext/opcache/Optimizer/compact_literals.c
index 28e7a11314..091437e119 100644
--- a/ext/opcache/Optimizer/compact_literals.c
+++ b/ext/opcache/Optimizer/compact_literals.c
@@ -40,6 +40,7 @@
#define LITERAL_STATIC_PROPERTY 0x0700
#define LITERAL_METHOD 0x0800
#define LITERAL_PROPERTY 0x0900
+#define LITERAL_GLOBAL 0x0A00
#define LITERAL_EX_CLASS 0x4000
#define LITERAL_EX_OBJ 0x2000
@@ -278,6 +279,9 @@ void zend_optimizer_compact_literals(zend_op_array *op_array, zend_optimizer_ctx
}
}
break;
+ case ZEND_BIND_GLOBAL:
+ LITERAL_INFO(opline->op2.constant, LITERAL_GLOBAL, 0, 1, 1);
+ break;
default:
if (ZEND_OP1_TYPE(opline) == IS_CONST) {
LITERAL_INFO(opline->op1.constant, LITERAL_VALUE, 1, 0, 1);
diff --git a/ext/opcache/Optimizer/nop_removal.c b/ext/opcache/Optimizer/nop_removal.c
index bea42229f6..651950148c 100644
--- a/ext/opcache/Optimizer/nop_removal.c
+++ b/ext/opcache/Optimizer/nop_removal.c
@@ -97,7 +97,7 @@ void zend_optimizer_nop_removal(zend_op_array *op_array)
case ZEND_FE_RESET:
case ZEND_NEW:
case ZEND_JMP_SET:
- case ZEND_JMP_SET_VAR:
+ case ZEND_COALESCE:
ZEND_OP2(opline).opline_num -= shiftlist[ZEND_OP2(opline).opline_num];
break;
case ZEND_JMPZNZ:
diff --git a/ext/opcache/Optimizer/pass1_5.c b/ext/opcache/Optimizer/pass1_5.c
index def060c66c..f06f5cc559 100644
--- a/ext/opcache/Optimizer/pass1_5.c
+++ b/ext/opcache/Optimizer/pass1_5.c
@@ -91,7 +91,7 @@ void zend_optimizer_pass1(zend_op_array *op_array, zend_optimizer_ctx *ctx TSRML
literal_dtor(&ZEND_OP2_LITERAL(opline));
MAKE_NOP(opline);
- zend_optimizer_replace_tmp_by_const(op_array, opline + 1, tv, &result TSRMLS_CC);
+ zend_optimizer_replace_by_const(op_array, opline + 1, IS_TMP_VAR, tv, &result TSRMLS_CC);
}
break;
@@ -101,6 +101,7 @@ void zend_optimizer_pass1(zend_op_array *op_array, zend_optimizer_ctx *ctx TSRML
opline->extended_value != IS_OBJECT &&
opline->extended_value != IS_RESOURCE) {
/* cast of constant operand */
+ zend_uchar type = opline->result_type;
uint32_t tv = ZEND_RESULT(opline).var; /* temporary variable */
zval res;
res = ZEND_OP1_LITERAL(opline);
@@ -126,11 +127,7 @@ void zend_optimizer_pass1(zend_op_array *op_array, zend_optimizer_ctx *ctx TSRML
literal_dtor(&ZEND_OP1_LITERAL(opline));
MAKE_NOP(opline);
- if (opline->result_type == IS_TMP_VAR) {
- zend_optimizer_replace_tmp_by_const(op_array, opline + 1, tv, &res TSRMLS_CC);
- } else /* if (opline->result_type == IS_VAR) */ {
- zend_optimizer_replace_var_by_const(op_array, opline + 1, tv, &res TSRMLS_CC);
- }
+ zend_optimizer_replace_by_const(op_array, opline + 1, type, tv, &res TSRMLS_CC);
} else if (opline->extended_value == _IS_BOOL) {
/* T = CAST(X, IS_BOOL) => T = BOOL(X) */
opline->opcode = ZEND_BOOL;
@@ -157,7 +154,7 @@ void zend_optimizer_pass1(zend_op_array *op_array, zend_optimizer_ctx *ctx TSRML
literal_dtor(&ZEND_OP1_LITERAL(opline));
MAKE_NOP(opline);
- zend_optimizer_replace_tmp_by_const(op_array, opline + 1, tv, &result TSRMLS_CC);
+ zend_optimizer_replace_by_const(op_array, opline + 1, IS_TMP_VAR, tv, &result TSRMLS_CC);
}
break;
@@ -251,7 +248,7 @@ void zend_optimizer_pass1(zend_op_array *op_array, zend_optimizer_ctx *ctx TSRML
literal_dtor(&ZEND_OP2_LITERAL(opline));
MAKE_NOP(opline);
- zend_optimizer_replace_tmp_by_const(op_array, opline, tv, offset TSRMLS_CC);
+ zend_optimizer_replace_by_const(op_array, opline, IS_TMP_VAR, tv, offset TSRMLS_CC);
}
EG(current_execute_data) = orig_execute_data;
break;
@@ -271,7 +268,7 @@ void zend_optimizer_pass1(zend_op_array *op_array, zend_optimizer_ctx *ctx TSRML
}
literal_dtor(&ZEND_OP2_LITERAL(opline));
MAKE_NOP(opline);
- zend_optimizer_replace_tmp_by_const(op_array, opline, tv, &c TSRMLS_CC);
+ zend_optimizer_replace_by_const(op_array, opline, IS_TMP_VAR, tv, &c TSRMLS_CC);
}
/* class constant */
@@ -332,7 +329,7 @@ void zend_optimizer_pass1(zend_op_array *op_array, zend_optimizer_ctx *ctx TSRML
}
literal_dtor(&ZEND_OP2_LITERAL(opline));
MAKE_NOP(opline);
- zend_optimizer_replace_tmp_by_const(op_array, opline, tv, &t TSRMLS_CC);
+ zend_optimizer_replace_by_const(op_array, opline, IS_TMP_VAR, tv, &t TSRMLS_CC);
}
}
}
@@ -388,7 +385,7 @@ void zend_optimizer_pass1(zend_op_array *op_array, zend_optimizer_ctx *ctx TSRML
func->module->type == MODULE_PERSISTENT) {
zval t;
ZVAL_BOOL(&t, 1);
- if (zend_optimizer_replace_var_by_const(op_array, opline + 3, ZEND_RESULT(opline + 2).var, &t TSRMLS_CC)) {
+ if (zend_optimizer_replace_by_const(op_array, opline + 3, IS_VAR, ZEND_RESULT(opline + 2).var, &t TSRMLS_CC)) {
literal_dtor(&ZEND_OP2_LITERAL(opline));
MAKE_NOP(opline);
literal_dtor(&ZEND_OP1_LITERAL(opline + 1));
@@ -421,7 +418,7 @@ void zend_optimizer_pass1(zend_op_array *op_array, zend_optimizer_ctx *ctx TSRML
}
}
- if (zend_optimizer_replace_var_by_const(op_array, opline + 3, ZEND_RESULT(opline + 2).var, &t TSRMLS_CC)) {
+ if (zend_optimizer_replace_by_const(op_array, opline + 3, IS_VAR, ZEND_RESULT(opline + 2).var, &t TSRMLS_CC)) {
literal_dtor(&ZEND_OP2_LITERAL(opline));
MAKE_NOP(opline);
literal_dtor(&ZEND_OP1_LITERAL(opline + 1));
@@ -436,7 +433,7 @@ void zend_optimizer_pass1(zend_op_array *op_array, zend_optimizer_ctx *ctx TSRML
if (zend_optimizer_get_persistent_constant(Z_STR(ZEND_OP1_LITERAL(opline + 1)), &t, 0 TSRMLS_CC)) {
ZVAL_BOOL(&t, 1);
- if (zend_optimizer_replace_var_by_const(op_array, opline + 3, ZEND_RESULT(opline + 2).var, &t TSRMLS_CC)) {
+ if (zend_optimizer_replace_by_const(op_array, opline + 3, IS_VAR, ZEND_RESULT(opline + 2).var, &t TSRMLS_CC)) {
literal_dtor(&ZEND_OP2_LITERAL(opline));
MAKE_NOP(opline);
literal_dtor(&ZEND_OP1_LITERAL(opline + 1));
@@ -450,7 +447,7 @@ void zend_optimizer_pass1(zend_op_array *op_array, zend_optimizer_ctx *ctx TSRML
zval t;
if (zend_optimizer_get_persistent_constant(Z_STR(ZEND_OP1_LITERAL(opline + 1)), &t, 1 TSRMLS_CC)) {
- if (zend_optimizer_replace_var_by_const(op_array, opline + 3, ZEND_RESULT(opline + 2).var, &t TSRMLS_CC)) {
+ if (zend_optimizer_replace_by_const(op_array, opline + 3, IS_VAR, ZEND_RESULT(opline + 2).var, &t TSRMLS_CC)) {
literal_dtor(&ZEND_OP2_LITERAL(opline));
MAKE_NOP(opline);
literal_dtor(&ZEND_OP1_LITERAL(opline + 1));
@@ -465,7 +462,7 @@ void zend_optimizer_pass1(zend_op_array *op_array, zend_optimizer_ctx *ctx TSRML
zval t;
ZVAL_LONG(&t, Z_STRLEN(ZEND_OP1_LITERAL(opline + 1)));
- if (zend_optimizer_replace_var_by_const(op_array, opline + 3, ZEND_RESULT(opline + 2).var, &t TSRMLS_CC)) {
+ if (zend_optimizer_replace_by_const(op_array, opline + 3, IS_VAR, ZEND_RESULT(opline + 2).var, &t TSRMLS_CC)) {
literal_dtor(&ZEND_OP2_LITERAL(opline));
MAKE_NOP(opline);
literal_dtor(&ZEND_OP1_LITERAL(opline + 1));
@@ -481,7 +478,7 @@ void zend_optimizer_pass1(zend_op_array *op_array, zend_optimizer_ctx *ctx TSRML
zval t;
ZVAL_LONG(&t, Z_STRLEN(ZEND_OP1_LITERAL(opline)));
- zend_optimizer_replace_tmp_by_const(op_array, opline + 1, ZEND_RESULT(opline).var, &t TSRMLS_CC);
+ zend_optimizer_replace_by_const(op_array, opline + 1, IS_TMP_VAR, ZEND_RESULT(opline).var, &t TSRMLS_CC);
literal_dtor(&ZEND_OP1_LITERAL(opline));
MAKE_NOP(opline);
}
@@ -494,7 +491,7 @@ void zend_optimizer_pass1(zend_op_array *op_array, zend_optimizer_ctx *ctx TSRML
break;
}
ZVAL_TRUE(&c);
- zend_optimizer_replace_tmp_by_const(op_array, opline, tv, &c TSRMLS_CC);
+ zend_optimizer_replace_by_const(op_array, opline, IS_TMP_VAR, tv, &c TSRMLS_CC);
literal_dtor(&ZEND_OP1_LITERAL(opline));
MAKE_NOP(opline);
}
@@ -529,7 +526,7 @@ void zend_optimizer_pass1(zend_op_array *op_array, zend_optimizer_ctx *ctx TSRML
case ZEND_NEW:
case ZEND_DO_FCALL:
case ZEND_JMP_SET:
- case ZEND_JMP_SET_VAR:
+ case ZEND_COALESCE:
collect_constants = 0;
break;
case ZEND_FETCH_R:
diff --git a/ext/opcache/Optimizer/pass2.c b/ext/opcache/Optimizer/pass2.c
index 5fa6560d48..859bc2f3bc 100644
--- a/ext/opcache/Optimizer/pass2.c
+++ b/ext/opcache/Optimizer/pass2.c
@@ -205,8 +205,7 @@ void zend_optimizer_pass2(zend_op_array *op_array TSRMLS_DC)
array_offset = jmp_to->parent;
if (--nest_levels > 0) {
if (opline->opcode == ZEND_BRK &&
- (op_array->opcodes[jmp_to->brk].opcode == ZEND_FREE ||
- op_array->opcodes[jmp_to->brk].opcode == ZEND_SWITCH_FREE)) {
+ op_array->opcodes[jmp_to->brk].opcode == ZEND_FREE) {
dont_optimize = 1;
break;
}
diff --git a/ext/opcache/Optimizer/pass3.c b/ext/opcache/Optimizer/pass3.c
index 511431bb2c..8d8cb50580 100644
--- a/ext/opcache/Optimizer/pass3.c
+++ b/ext/opcache/Optimizer/pass3.c
@@ -182,7 +182,7 @@ void zend_optimizer_pass3(zend_op_array *op_array TSRMLS_DC)
break;
case ZEND_JMP_SET:
- case ZEND_JMP_SET_VAR:
+ case ZEND_COALESCE:
if (op_array->fn_flags & ZEND_ACC_HAS_FINALLY_BLOCK) {
break;
}
diff --git a/ext/opcache/Optimizer/zend_optimizer.c b/ext/opcache/Optimizer/zend_optimizer.c
index 6d011afc60..cd75817e0c 100644
--- a/ext/opcache/Optimizer/zend_optimizer.c
+++ b/ext/opcache/Optimizer/zend_optimizer.c
@@ -262,15 +262,16 @@ check_numeric:
}
}
-int zend_optimizer_replace_var_by_const(zend_op_array *op_array,
- zend_op *opline,
- uint32_t var,
- zval *val TSRMLS_DC)
+int zend_optimizer_replace_by_const(zend_op_array *op_array,
+ zend_op *opline,
+ zend_uchar type,
+ uint32_t var,
+ zval *val TSRMLS_DC)
{
zend_op *end = op_array->opcodes + op_array->last;
while (opline < end) {
- if (ZEND_OP1_TYPE(opline) == IS_VAR &&
+ if (ZEND_OP1_TYPE(opline) == type &&
ZEND_OP1(opline).var == var) {
switch (opline->opcode) {
case ZEND_FETCH_DIM_W:
@@ -292,6 +293,25 @@ int zend_optimizer_replace_var_by_const(zend_op_array *op_array,
opline->opcode = ZEND_SEND_VAL;
}
break;
+ /* In most cases IS_TMP_VAR operand may be used only once.
+ * The operands are usually destroyed by the opcode handler.
+ * ZEND_CASE is an exception, that keeps operand unchanged,
+ * and allows its reuse. The number of ZEND_CASE instructions
+ * usually terminated by ZEND_FREE that finally kills the value.
+ */
+ case ZEND_CASE: {
+ zval old_val;
+ ZVAL_COPY_VALUE(&old_val, val);
+ zval_copy_ctor(val);
+ zend_optimizer_update_op1_const(op_array, opline, val TSRMLS_CC);
+ ZVAL_COPY_VALUE(val, &old_val);
+ opline++;
+ continue;
+ }
+ case ZEND_FREE:
+ MAKE_NOP(opline);
+ zval_dtor(val);
+ return 1;
default:
break;
}
@@ -299,7 +319,7 @@ int zend_optimizer_replace_var_by_const(zend_op_array *op_array,
break;
}
- if (ZEND_OP2_TYPE(opline) == IS_VAR &&
+ if (ZEND_OP2_TYPE(opline) == type &&
ZEND_OP2(opline).var == var) {
switch (opline->opcode) {
case ZEND_ASSIGN_REF:
@@ -316,55 +336,6 @@ int zend_optimizer_replace_var_by_const(zend_op_array *op_array,
return 1;
}
-void zend_optimizer_replace_tmp_by_const(zend_op_array *op_array,
- zend_op *opline,
- uint32_t var,
- zval *val
- TSRMLS_DC)
-{
- zend_op *end = op_array->opcodes + op_array->last;
-
- while (opline < end) {
- if (ZEND_OP1_TYPE(opline) == IS_TMP_VAR &&
- ZEND_OP1(opline).var == var) {
-
- /* In most cases IS_TMP_VAR operand may be used only once.
- * The operands are usually destroyed by the opcode handler.
- * ZEND_CASE is an exception, that keeps operand unchanged,
- * and allows its reuse. The number of ZEND_CASE instructions
- * usually terminated by ZEND_FREE that finally kills the value.
- */
- if (opline->opcode == ZEND_CASE) {
- zval old_val;
- ZVAL_COPY_VALUE(&old_val, val);
- zval_copy_ctor(val);
- zend_optimizer_update_op1_const(op_array, opline, val TSRMLS_CC);
- ZVAL_COPY_VALUE(val, &old_val);
- } else if (opline->opcode == ZEND_FREE) {
- MAKE_NOP(opline);
- break;
- } else {
- zend_optimizer_update_op1_const(op_array, opline, val TSRMLS_CC);
- val = NULL;
- break;
- }
- }
-
- if (ZEND_OP2_TYPE(opline) == IS_TMP_VAR &&
- ZEND_OP2(opline).var == var) {
-
- zend_optimizer_update_op2_const(op_array, opline, val TSRMLS_CC);
- /* TMP_VAR may be used only once */
- val = NULL;
- break;
- }
- opline++;
- }
- if (val) {
- zval_dtor(val);
- }
-}
-
static void zend_optimize(zend_op_array *op_array,
zend_optimizer_ctx *ctx TSRMLS_DC)
{
@@ -467,7 +438,7 @@ static void zend_accel_optimize(zend_op_array *op_array,
case ZEND_JMPZ_EX:
case ZEND_JMPNZ_EX:
case ZEND_JMP_SET:
- case ZEND_JMP_SET_VAR:
+ case ZEND_COALESCE:
case ZEND_NEW:
case ZEND_FE_RESET:
case ZEND_FE_FETCH:
@@ -505,7 +476,7 @@ static void zend_accel_optimize(zend_op_array *op_array,
case ZEND_JMPZ_EX:
case ZEND_JMPNZ_EX:
case ZEND_JMP_SET:
- case ZEND_JMP_SET_VAR:
+ case ZEND_COALESCE:
case ZEND_NEW:
case ZEND_FE_RESET:
case ZEND_FE_FETCH:
diff --git a/ext/opcache/Optimizer/zend_optimizer_internal.h b/ext/opcache/Optimizer/zend_optimizer_internal.h
index ac87cf9f35..ba91b147c9 100644
--- a/ext/opcache/Optimizer/zend_optimizer_internal.h
+++ b/ext/opcache/Optimizer/zend_optimizer_internal.h
@@ -112,14 +112,11 @@ void zend_optimizer_update_op1_const(zend_op_array *op_array,
void zend_optimizer_update_op2_const(zend_op_array *op_array,
zend_op *opline,
zval *val TSRMLS_DC);
-int zend_optimizer_replace_var_by_const(zend_op_array *op_array,
- zend_op *opline,
- uint32_t var,
- zval *val TSRMLS_DC);
-void zend_optimizer_replace_tmp_by_const(zend_op_array *op_array,
- zend_op *opline,
- uint32_t var,
- zval *val TSRMLS_DC);
+int zend_optimizer_replace_by_const(zend_op_array *op_array,
+ zend_op *opline,
+ zend_uchar type,
+ uint32_t var,
+ zval *val TSRMLS_DC);
void zend_optimizer_pass1(zend_op_array *op_array, zend_optimizer_ctx *ctx TSRMLS_DC);
void zend_optimizer_pass2(zend_op_array *op_array TSRMLS_DC);
diff --git a/ext/opcache/ZendAccelerator.c b/ext/opcache/ZendAccelerator.c
index d72383ace8..b5c20f91e4 100644
--- a/ext/opcache/ZendAccelerator.c
+++ b/ext/opcache/ZendAccelerator.c
@@ -384,6 +384,9 @@ static void accel_use_shm_interned_strings(TSRMLS_D)
if (p->key) {
p->key = accel_new_interned_string(p->key TSRMLS_CC);
}
+ if (Z_FUNC(p->val)->common.function_name) {
+ Z_FUNC(p->val)->common.function_name = accel_new_interned_string(Z_FUNC(p->val)->common.function_name TSRMLS_CC);
+ }
}
/* class table hash keys, class names, properties, methods, constants, etc */
@@ -425,6 +428,9 @@ static void accel_use_shm_interned_strings(TSRMLS_D)
if (q->key) {
q->key = accel_new_interned_string(q->key TSRMLS_CC);
}
+ if (Z_FUNC(q->val)->common.function_name) {
+ Z_FUNC(q->val)->common.function_name = accel_new_interned_string(Z_FUNC(q->val)->common.function_name TSRMLS_CC);
+ }
}
for (j = 0; j < ce->constants_table.nNumUsed; j++) {
@@ -1913,6 +1919,7 @@ static void accel_activate(void)
* allocated block separately, but we like to call all the destructors and
* callbacks in exactly the same order.
*/
+static void accel_fast_zval_dtor(zval *zvalue);
static void accel_fast_hash_destroy(HashTable *ht)
{
@@ -1922,7 +1929,7 @@ static void accel_fast_hash_destroy(HashTable *ht)
for (idx = 0; idx < ht->nNumUsed; idx++) {
p = ht->arData + idx;
if (Z_TYPE(p->val) == IS_UNDEF) continue;
- ht->pDestructor(&p->val);
+ accel_fast_zval_dtor(&p->val);
}
}
@@ -1936,7 +1943,6 @@ static void accel_fast_zval_dtor(zval *zvalue)
if (Z_ARR_P(zvalue) != &EG(symbol_table)) {
/* break possible cycles */
ZVAL_NULL(zvalue);
- Z_ARRVAL_P(zvalue)->pDestructor = accel_fast_zval_dtor;
accel_fast_hash_destroy(Z_ARRVAL_P(zvalue));
}
}
@@ -1978,61 +1984,29 @@ static int accel_clean_non_persistent_function(zval *zv TSRMLS_DC)
return ZEND_HASH_APPLY_STOP;
} else {
if (function->op_array.static_variables) {
- function->op_array.static_variables->pDestructor = accel_fast_zval_dtor;
accel_fast_hash_destroy(function->op_array.static_variables);
function->op_array.static_variables = NULL;
}
- return (--(*function->op_array.refcount) <= 0) ?
- ZEND_HASH_APPLY_REMOVE :
- ZEND_HASH_APPLY_KEEP;
- }
-}
-
-static int accel_cleanup_function_data(zval *zv TSRMLS_DC)
-{
- zend_function *function = Z_PTR_P(zv);
-
- if (function->type == ZEND_USER_FUNCTION) {
- if (function->op_array.static_variables) {
- function->op_array.static_variables->pDestructor = accel_fast_zval_dtor;
- accel_fast_hash_destroy(function->op_array.static_variables);
- function->op_array.static_variables = NULL;
- }
- }
- return 0;
-}
-
-static int accel_clean_non_persistent_class(zval *zv TSRMLS_DC)
-{
- zend_class_entry *ce = Z_PTR_P(zv);
-
- if (ce->type == ZEND_INTERNAL_CLASS) {
- return ZEND_HASH_APPLY_STOP;
- } else {
- if (ce->ce_flags & ZEND_HAS_STATIC_IN_METHODS) {
- zend_hash_apply(&ce->function_table, (apply_func_t) accel_cleanup_function_data TSRMLS_CC);
- }
- if (ce->static_members_table) {
- int i;
-
- for (i = 0; i < ce->default_static_members_count; i++) {
- accel_fast_zval_dtor(&ce->static_members_table[i]);
- ZVAL_UNDEF(&ce->static_members_table[i]);
- }
- ce->static_members_table = NULL;
- }
return ZEND_HASH_APPLY_REMOVE;
}
}
-static int accel_clean_non_persistent_constant(zval *zv TSRMLS_DC)
+static inline void zend_accel_fast_del_bucket(HashTable *ht, uint32_t idx, Bucket *p)
{
- zend_constant *c = Z_PTR_P(zv);
+ uint32_t nIndex = p->h & ht->nTableMask;
+ uint32_t i = ht->arHash[nIndex];
- if (c->flags & CONST_PERSISTENT) {
- return ZEND_HASH_APPLY_STOP;
- } else {
- return ZEND_HASH_APPLY_REMOVE;
+ ht->nNumUsed--;
+ ht->nNumOfElements--;
+ if (idx != i) {
+ Bucket *prev = ht->arData + i;
+ while (Z_NEXT(prev->val) != idx) {
+ i = Z_NEXT(prev->val);
+ prev = ht->arData + i;
+ }
+ Z_NEXT(prev->val) = Z_NEXT(p->val);
+ } else {
+ ht->arHash[p->h & ht->nTableMask] = Z_NEXT(p->val);
}
}
@@ -2054,18 +2028,60 @@ static void zend_accel_fast_shutdown(TSRMLS_D)
EG(symbol_table).ht.pDestructor = old_destructor;
}
zend_hash_init(&EG(symbol_table).ht, 8, NULL, NULL, 0);
- old_destructor = EG(function_table)->pDestructor;
- EG(function_table)->pDestructor = NULL;
- zend_hash_reverse_apply(EG(function_table), (apply_func_t) accel_clean_non_persistent_function TSRMLS_CC);
- EG(function_table)->pDestructor = old_destructor;
- old_destructor = EG(class_table)->pDestructor;
- EG(class_table)->pDestructor = NULL;
- zend_hash_reverse_apply(EG(class_table), (apply_func_t) accel_clean_non_persistent_class TSRMLS_CC);
- EG(class_table)->pDestructor = old_destructor;
- old_destructor = EG(zend_constants)->pDestructor;
- EG(zend_constants)->pDestructor = NULL;
- zend_hash_reverse_apply(EG(zend_constants), (apply_func_t) accel_clean_non_persistent_constant TSRMLS_CC);
- EG(zend_constants)->pDestructor = old_destructor;
+
+ ZEND_HASH_REVERSE_FOREACH(EG(function_table), 0) {
+ zend_function *func = Z_PTR(_p->val);
+
+ if (func->type == ZEND_INTERNAL_FUNCTION) {
+ break;
+ } else {
+ if (func->op_array.static_variables) {
+ accel_fast_hash_destroy(func->op_array.static_variables);
+ }
+ zend_accel_fast_del_bucket(EG(function_table), _idx-1, _p);
+ }
+ } ZEND_HASH_FOREACH_END();
+
+ ZEND_HASH_REVERSE_FOREACH(EG(class_table), 0) {
+ zend_class_entry *ce = Z_PTR(_p->val);
+
+ if (ce->type == ZEND_INTERNAL_CLASS) {
+ break;
+ } else {
+ if (ce->ce_flags & ZEND_HAS_STATIC_IN_METHODS) {
+ zend_function *func;
+
+ ZEND_HASH_FOREACH_PTR(&ce->function_table, func) {
+ if (func->type == ZEND_USER_FUNCTION) {
+ if (func->op_array.static_variables) {
+ accel_fast_hash_destroy(func->op_array.static_variables);
+ func->op_array.static_variables = NULL;
+ }
+ }
+ } ZEND_HASH_FOREACH_END();
+ }
+ if (ce->static_members_table) {
+ int i;
+
+ for (i = 0; i < ce->default_static_members_count; i++) {
+ accel_fast_zval_dtor(&ce->static_members_table[i]);
+ ZVAL_UNDEF(&ce->static_members_table[i]);
+ }
+ ce->static_members_table = NULL;
+ }
+ zend_accel_fast_del_bucket(EG(class_table), _idx-1, _p);
+ }
+ } ZEND_HASH_FOREACH_END();
+
+ ZEND_HASH_REVERSE_FOREACH(EG(zend_constants), 0) {
+ zend_constant *c = Z_PTR(_p->val);
+
+ if (c->flags & CONST_PERSISTENT) {
+ break;
+ } else {
+ zend_accel_fast_del_bucket(EG(zend_constants), _idx-1, _p);
+ }
+ } ZEND_HASH_FOREACH_END();
}
CG(unclean_shutdown) = 1;
}
diff --git a/ext/opcache/zend_accelerator_util_funcs.c b/ext/opcache/zend_accelerator_util_funcs.c
index e04b1ec7db..59977717f7 100644
--- a/ext/opcache/zend_accelerator_util_funcs.c
+++ b/ext/opcache/zend_accelerator_util_funcs.c
@@ -75,7 +75,7 @@ zend_persistent_script* create_persistent_script(void)
zend_persistent_script *persistent_script = (zend_persistent_script *) emalloc(sizeof(zend_persistent_script));
memset(persistent_script, 0, sizeof(zend_persistent_script));
- zend_hash_init(&persistent_script->function_table, 128, NULL, (dtor_func_t) zend_accel_destroy_zend_function, 0);
+ zend_hash_init(&persistent_script->function_table, 128, NULL, ZEND_FUNCTION_DTOR, 0);
/* class_table is usually destroyed by free_persistent_script() that
* overrides destructor. ZEND_CLASS_DTOR may be used by standard
* PHP compiler
@@ -232,14 +232,14 @@ static inline zend_string *zend_clone_str(zend_string *str TSRMLS_DC)
if (IS_INTERNED(str)) {
ret = str;
- } else if (zend_string_refcount(str) <= 1 || (ret = accel_xlat_get(str)) == NULL) {
+ } else if (GC_REFCOUNT(str) <= 1 || (ret = accel_xlat_get(str)) == NULL) {
ret = zend_string_dup(str, 0);
GC_FLAGS(ret) = GC_FLAGS(str);
- if (zend_string_refcount(str) > 1) {
+ if (GC_REFCOUNT(str) > 1) {
accel_xlat_set(str, ret);
}
} else {
- zend_string_addref(ret);
+ GC_REFCOUNT(ret)++;
}
return ret;
}
diff --git a/ext/opcache/zend_persist.c b/ext/opcache/zend_persist.c
index b2b863c5a9..6491b9d781 100644
--- a/ext/opcache/zend_persist.c
+++ b/ext/opcache/zend_persist.c
@@ -373,7 +373,7 @@ static void zend_persist_op_array_ex(zend_op_array *op_array, zend_persistent_sc
case ZEND_JMPZ_EX:
case ZEND_JMPNZ_EX:
case ZEND_JMP_SET:
- case ZEND_JMP_SET_VAR:
+ case ZEND_COALESCE:
case ZEND_NEW:
case ZEND_FE_RESET:
case ZEND_FE_FETCH:
diff --git a/ext/opcache/zend_persist_calc.c b/ext/opcache/zend_persist_calc.c
index 76d1b043b0..d2de94f05c 100644
--- a/ext/opcache/zend_persist_calc.c
+++ b/ext/opcache/zend_persist_calc.c
@@ -120,7 +120,7 @@ static uint zend_persist_zval_calc(zval *z TSRMLS_DC)
case IS_CONSTANT:
flags = Z_GC_FLAGS_P(z) & ~ (IS_STR_PERSISTENT | IS_STR_INTERNED | IS_STR_PERMANENT);
ADD_INTERNED_STRING(Z_STR_P(z), 0);
- if (IS_INTERNED(Z_STR_P(z))) {
+ if (!Z_REFCOUNTED_P(z)) {
Z_TYPE_FLAGS_P(z) &= ~ (IS_TYPE_REFCOUNTED | IS_TYPE_COPYABLE);
}
Z_GC_FLAGS_P(z) |= flags;
diff --git a/ext/openssl/config0.m4 b/ext/openssl/config0.m4
index a97114f808..701e488385 100644
--- a/ext/openssl/config0.m4
+++ b/ext/openssl/config0.m4
@@ -8,6 +8,9 @@ PHP_ARG_WITH(openssl, for OpenSSL support,
PHP_ARG_WITH(kerberos, for Kerberos support,
[ --with-kerberos[=DIR] OPENSSL: Include Kerberos support], no, no)
+PHP_ARG_WITH(system-ciphers, whether to use system default cipher list instead of hardcoded value,
+[ --with-system-ciphers OPENSSL: Use system default cipher list instead of hardcoded value], no, no)
+
if test "$PHP_OPENSSL" != "no"; then
PHP_NEW_EXTENSION(openssl, openssl.c xp_ssl.c, $ext_shared)
PHP_SUBST(OPENSSL_SHARED_LIBADD)
@@ -25,4 +28,7 @@ if test "$PHP_OPENSSL" != "no"; then
], [
AC_MSG_ERROR([OpenSSL check failed. Please check config.log for more information.])
])
+ if test "$PHP_SYSTEM_CIPHERS" != "no"; then
+ AC_DEFINE(USE_OPENSSL_SYSTEM_CIPHERS,1,[ Use system default cipher list instead of hardcoded value ])
+ fi
fi
diff --git a/ext/openssl/openssl.c b/ext/openssl/openssl.c
index f2219dcd1e..c4b155b478 100755
--- a/ext/openssl/openssl.c
+++ b/ext/openssl/openssl.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -4386,7 +4386,7 @@ PHP_FUNCTION(openssl_private_encrypt)
if (successful) {
zval_dtor(crypted);
cryptedbuf->val[cryptedlen] = '\0';
- ZVAL_STR(crypted, cryptedbuf);
+ ZVAL_NEW_STR(crypted, cryptedbuf);
cryptedbuf = NULL;
RETVAL_TRUE;
}
@@ -4451,7 +4451,7 @@ PHP_FUNCTION(openssl_private_decrypt)
if (successful) {
zval_dtor(crypted);
cryptedbuf->val[cryptedlen] = '\0';
- ZVAL_STR(crypted, cryptedbuf);
+ ZVAL_NEW_STR(crypted, cryptedbuf);
cryptedbuf = NULL;
RETVAL_TRUE;
}
@@ -4509,7 +4509,7 @@ PHP_FUNCTION(openssl_public_encrypt)
if (successful) {
zval_dtor(crypted);
cryptedbuf->val[cryptedlen] = '\0';
- ZVAL_STR(crypted, cryptedbuf);
+ ZVAL_NEW_STR(crypted, cryptedbuf);
cryptedbuf = NULL;
RETVAL_TRUE;
}
@@ -4576,7 +4576,7 @@ PHP_FUNCTION(openssl_public_decrypt)
if (successful) {
zval_dtor(crypted);
cryptedbuf->val[cryptedlen] = '\0';
- ZVAL_STR(crypted, cryptedbuf);
+ ZVAL_NEW_STR(crypted, cryptedbuf);
cryptedbuf = NULL;
RETVAL_TRUE;
}
@@ -4660,7 +4660,7 @@ PHP_FUNCTION(openssl_sign)
zval_dtor(signature);
sigbuf->val[siglen] = '\0';
sigbuf->len = siglen;
- ZVAL_STR(signature, sigbuf);
+ ZVAL_NEW_STR(signature, sigbuf);
RETVAL_TRUE;
} else {
efree(sigbuf);
@@ -4812,7 +4812,7 @@ PHP_FUNCTION(openssl_seal)
if (len1 + len2 > 0) {
zval_dtor(sealdata);
buf[len1 + len2] = '\0';
- ZVAL_STR(sealdata, zend_string_init((char*)buf, len1 + len2, 0));
+ ZVAL_NEW_STR(sealdata, zend_string_init((char*)buf, len1 + len2, 0));
efree(buf);
zval_dtor(ekeys);
@@ -4903,7 +4903,7 @@ PHP_FUNCTION(openssl_open)
} else {
zval_dtor(opendata);
buf[len1 + len2] = '\0';
- ZVAL_STR(opendata, zend_string_init((char*)buf, len1 + len2, 0));
+ ZVAL_NEW_STR(opendata, zend_string_init((char*)buf, len1 + len2, 0));
efree(buf);
RETVAL_TRUE;
}
diff --git a/ext/openssl/openssl.dsp b/ext/openssl/openssl.dsp
deleted file mode 100644
index 857666a6a3..0000000000
--- a/ext/openssl/openssl.dsp
+++ /dev/null
@@ -1,111 +0,0 @@
-# Microsoft Developer Studio Project File - Name="openssl" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=openssl - Win32 Debug_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "openssl.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "openssl.mak" CFG="openssl - Win32 Debug_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "openssl - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "openssl - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "openssl - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MD /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "OPENSSL_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /D ZEND_DEBUG=0 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "COMPILE_DL_OPENSSL" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_OPENSSL_EXT=1 /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "NDEBUG"
-# ADD RSC /l 0x407 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 php5ts.lib ssleay32.lib libeay32.lib ws2_32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_openssl.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-
-!ELSEIF "$(CFG)" == "openssl - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "OPENSSL_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "COMPILE_DL_OPENSSL" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_OPENSSL_EXT=1 /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "_DEBUG"
-# ADD RSC /l 0x407 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 php5ts_debug.lib ssleay32.lib libeay32.lib ws2_32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_openssl.dll" /pdbtype:sept /libpath:"..\..\Debug_TS"
-
-!ENDIF
-
-# Begin Target
-
-# Name "openssl - Win32 Release_TS"
-# Name "openssl - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\openssl.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\xp_ssl.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_openssl.h
-# End Source File
-# End Group
-# End Target
-# End Project
diff --git a/ext/openssl/openssl.mak b/ext/openssl/openssl.mak
index a0c6fa483e..9bc053b662 100644
--- a/ext/openssl/openssl.mak
+++ b/ext/openssl/openssl.mak
@@ -4,7 +4,7 @@ PROJECT_ROOT = ..\..
# Module details
MODULE_NAME = php_ossl
-MODULE_DESC = "PHP 5 - OpenSSL Extension"
+MODULE_DESC = "PHP 7 - OpenSSL Extension"
VMAJ = 1
VMIN = 0
VREV = 0
diff --git a/ext/openssl/php_openssl.h b/ext/openssl/php_openssl.h
index 968919eb64..08a9656b71 100644
--- a/ext/openssl/php_openssl.h
+++ b/ext/openssl/php_openssl.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/openssl/tests/bug65729.pem b/ext/openssl/tests/bug65729.pem
index dbeed6efd3..f0d44a4c78 100644
--- a/ext/openssl/tests/bug65729.pem
+++ b/ext/openssl/tests/bug65729.pem
@@ -1,28 +1,28 @@
-----BEGIN CERTIFICATE-----
-MIICCTCCAXICCQDNMI29sowT7TANBgkqhkiG9w0BAQUFADBJMQswCQYDVQQGEwJT
+MIICCTCCAXICCQCx2JwIhbRefzANBgkqhkiG9w0BAQUFADBJMQswCQYDVQQGEwJT
RzESMBAGA1UECBMJVGVzdHZpbGxlMREwDwYDVQQKEwhkYXRpYmJhdzETMBEGA1UE
-AxQKKi50ZXN0LmNvbTAeFw0xMzA5MjEwNzUyMjRaFw0xNDA5MjEwNzUyMjRaMEkx
+AxQKKi50ZXN0LmNvbTAeFw0xNDA5MjQxMTMzNTRaFw0yNDA5MjExMTMzNTRaMEkx
CzAJBgNVBAYTAlNHMRIwEAYDVQQIEwlUZXN0dmlsbGUxETAPBgNVBAoTCGRhdGli
YmF3MRMwEQYDVQQDFAoqLnRlc3QuY29tMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCB
-iQKBgQCdzVnic8K5W4SVbwVuqezcTjeqVLoQ91vVNZB0Jnsuz6q3DoK03oAd1jTe
-Vd0k+MQDbXpHoc37lA4+8z/g5Bs0UXxNx+nkbFTE7Ba2/G24caI9/cOXZPG3UViD
-rtqXKL6h5/umqRG9Dt5liF2MVP9XFAesVC7B8+Ca+PbPlQoYzwIDAQABMA0GCSqG
-SIb3DQEBBQUAA4GBAAS07u/Ke+EhEHidz6CG3Qcr+zg483JKRgZFyGz+YUKyyKKy
-fmLs7JieGJxYQjOmIpj/6X9Gnb2HjIPDnI6A+MV1emXDTnnmsgf2/lZGcthhpZn2
-rMbj9bI0iH6HwOVGtp4ZJA5fB7nj3J+gWNTCQzDDOxwX36d2LL9ua+UMnk/g
+iQKBgQDBnR8DYzsN90kISI87kBvw40TQknS7/fuymWCmSrtRQLED8p2QL8PiYCZ8
+UdcFVsv+di7MJvUOzW6dRo2DCu8Rojx3ML8dAtPsQkDdaCXDnOvCTQCAqFmxa1A9
+c5kp0hbzCrucKGckb355A4NumFgX1fjQ705MfjGPgQef1ZtozQIDAQABMA0GCSqG
+SIb3DQEBBQUAA4GBAGP07nJo0pI4FdsXuAHWr97XxV4EhHopFMw6svOZ3UtsRzmW
+ScmmMdgd3c8ciVxOsztgnzvFq/nrUkw/3n/Xz/gtE7kZt9aS18SnCyyHPJcXmmUE
+NsbyZ/7srIqCSrxUkP+N//nToqHxg1pqA/A8RzOOQUAp+UIVF6Zl/kkFNgt8
-----END CERTIFICATE-----
-----BEGIN RSA PRIVATE KEY-----
-MIICXQIBAAKBgQCdzVnic8K5W4SVbwVuqezcTjeqVLoQ91vVNZB0Jnsuz6q3DoK0
-3oAd1jTeVd0k+MQDbXpHoc37lA4+8z/g5Bs0UXxNx+nkbFTE7Ba2/G24caI9/cOX
-ZPG3UViDrtqXKL6h5/umqRG9Dt5liF2MVP9XFAesVC7B8+Ca+PbPlQoYzwIDAQAB
-AoGAeyzTwKPDl5QMRejHQL57GOwlH1vLcXrjv+VzwHZZKQ0IoKM++5fCQYf29KXp
-XPahaluGW2u9sWa8R/7wGcd0Q4RtquGzsgT3+AQsIc5KfIamyOyDaRVM/ymX3fWg
-gHIU7OOzB+ihOU8sHyRIwfbk01/kmrBXLRj8E31sy3i3PIECQQDQQYE+aN7Acrdt
-yN5CaqvbkiCGjRvASlemiTzPosgOtndyp21w1gakJwKYhYDk1N6A6Qb8REMZqM/U
-wFypldV/AkEAwfq6NFuhpGL6hDA7MvlyY1KiZ0cHetPUX+PgdNqy2DA+1Sv4i7gm
-Wd/uA651K7aPXuUaf9dKtPCmZwI4M6SEsQJBALW89HTqP7niYoDEEnITdPaghxHk
-gptERUln6lGo1L1CLus3gSI/JHyMLo+7scgAnEwTD62GRKhX0Ubwt+ymfTECQAY5
-fHYnppU20+EgBxZIqOIFCc8UmWnYmE0Ha/Fz/x8u1SVUBuK84wYpSGL32yyu7ATY
-hzQo/W229zABAzqtAdECQQCUdB7IBFpPnsfv/EUBFX7X/7zAc9JpACmu9It5ju8C
-KIsMuz/02D+TQoJNjdAngBM+4AJDIaGFgTMIfaDMh5L7
+MIICXgIBAAKBgQDBnR8DYzsN90kISI87kBvw40TQknS7/fuymWCmSrtRQLED8p2Q
+L8PiYCZ8UdcFVsv+di7MJvUOzW6dRo2DCu8Rojx3ML8dAtPsQkDdaCXDnOvCTQCA
+qFmxa1A9c5kp0hbzCrucKGckb355A4NumFgX1fjQ705MfjGPgQef1ZtozQIDAQAB
+AoGADAnkAsbpxh2JKf2xAkgcpKbNAZcJsSLCwsEstEpTSWMXXqJ4T53YtTu7SOGh
+2BAkkQbyM/l8JVZ6uUbIx8wnPzqAuB2hEDQHKZVyftDyJh+54Uyz0xV0JdWGWrFh
+A+uDt/Zncx2g+qlkQG5J5nHnrd9OAns89wJXpBWA6twlsuECQQD/HC4wxOJzh1XI
+YSWHWQulOnlNgZ2zERfmJeRfJ0ncmDOV2ofxOFQ+dMJ36XghPaH52KdxqWI1yQaE
+yesx8ygFAkEAwkoF4lBuYdsXucJNDYf8o9MlBvazoriH0y26B/YozJ7iAEFqVvcC
+TN+iKDIyiRALwR6a3nzhyFYJ4xyzgSIAKQJBAMnw3seQMsnM6aTS8cgwPr2uifNG
+lTT4ZPi0KhEAosFSYhNPh6j1NAq0lnQhhgyaIywJypJ4yNtWpChdRiamGpkCQQDB
+iUExPpOmMLwCk7VzrCmS+6pftHIevpi2WU99zMy5f+969665MFb/QqniRpamh/Bd
+kGIPDPFQQbyZmqaJFNh5AkEAzy0YVbUT3C/QvstPr5i7ztj7WiW/1zJMamFwY/ZS
+1J7e7lqHgRICie5uv1Yvh3w/qmV/7lTLhmlQZd9SJMpXhg==
-----END RSA PRIVATE KEY-----
diff --git a/ext/openssl/xp_ssl.c b/ext/openssl/xp_ssl.c
index 7954fb753a..54562c22e5 100644
--- a/ext/openssl/xp_ssl.c
+++ b/ext/openssl/xp_ssl.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -28,7 +28,7 @@
#include "ext/standard/file.h"
#include "ext/standard/url.h"
#include "streams/php_streams_int.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#include "php_openssl.h"
#include "php_network.h"
#include <openssl/ssl.h>
@@ -1453,13 +1453,16 @@ int php_openssl_setup_crypto(php_stream *stream,
}
GET_VER_OPT_STRING("ciphers", cipherlist);
+#ifndef USE_OPENSSL_SYSTEM_CIPHERS
if (!cipherlist) {
cipherlist = OPENSSL_DEFAULT_STREAM_CIPHERS;
}
- if (SSL_CTX_set_cipher_list(sslsock->ctx, cipherlist) != 1) {
- return FAILURE;
+#endif
+ if (cipherlist) {
+ if (SSL_CTX_set_cipher_list(sslsock->ctx, cipherlist) != 1) {
+ return FAILURE;
+ }
}
-
if (FAILURE == set_local_cert(sslsock->ctx, stream TSRMLS_CC)) {
return FAILURE;
}
@@ -1820,7 +1823,7 @@ static size_t php_openssl_sockop_read(php_stream *stream, char *buf, size_t coun
to hang forever. To avoid this scenario we poll with a timeout before performing
the actual read. If it times out we're finished.
*/
- if (sock->is_blocked) {
+ if (sock->is_blocked && SSL_pending(sslsock->ssl_handle) == 0) {
php_openssl_stream_wait_for_data(sock);
if (sock->timeout_event) {
stream->eof = 1;
@@ -2146,17 +2149,19 @@ static int php_openssl_sockop_cast(php_stream *stream, int castas, void **ret TS
case PHP_STREAM_AS_FD_FOR_SELECT:
if (ret) {
- if (sslsock->ssl_active) {
- /* OpenSSL has an internal buffer which select() cannot see. If we don't
- fetch it into the stream's buffer, no activity will be reported on the
- stream even though there is data waiting to be read - but we only fetch
- the number of bytes OpenSSL has ready to give us since we weren't asked
- for any data at this stage. This is only likely to cause issues with
- non-blocking streams, but it's harmless to always do it. */
- int bytes;
- while ((bytes = SSL_pending(sslsock->ssl_handle)) > 0) {
- php_stream_fill_read_buffer(stream, (size_t)bytes);
- }
+ /* OpenSSL has an internal buffer which select() cannot see. If we don't
+ * fetch it into the stream's buffer, no activity will be reported on the
+ * stream even though there is data waiting to be read - but we only fetch
+ * the lower of bytes OpenSSL has ready to give us or chunk_size since we
+ * weren't asked for any data at this stage. This is only likely to cause
+ * issues with non-blocking streams, but it's harmless to always do it. */
+ size_t pending;
+ if (stream->writepos == stream->readpos
+ && sslsock->ssl_active
+ && (pending = (size_t)SSL_pending(sslsock->ssl_handle)) > 0) {
+ php_stream_fill_read_buffer(stream, pending < stream->chunk_size
+ ? pending
+ : stream->chunk_size);
}
*(php_socket_t *)ret = sslsock->s.socket;
diff --git a/ext/pcntl/pcntl.c b/ext/pcntl/pcntl.c
index 5595f31b58..11ad1018ec 100644
--- a/ext/pcntl/pcntl.c
+++ b/ext/pcntl/pcntl.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pcntl/php_pcntl.h b/ext/pcntl/php_pcntl.h
index 05c7f45566..d02d6867f4 100644
--- a/ext/pcntl/php_pcntl.h
+++ b/ext/pcntl/php_pcntl.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pcntl/php_signal.c b/ext/pcntl/php_signal.c
index 9f308d793c..aa2139342c 100644
--- a/ext/pcntl/php_signal.c
+++ b/ext/pcntl/php_signal.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pcntl/php_signal.h b/ext/pcntl/php_signal.h
index 5c61b10396..fc69fac756 100644
--- a/ext/pcntl/php_signal.h
+++ b/ext/pcntl/php_signal.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pcre/php_pcre.c b/ext/pcre/php_pcre.c
index 89c5f1155b..67857da2c7 100644
--- a/ext/pcre/php_pcre.c
+++ b/ext/pcre/php_pcre.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -23,7 +23,7 @@
#include "php_globals.h"
#include "php_pcre.h"
#include "ext/standard/info.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#if HAVE_PCRE || HAVE_BUNDLED_PCRE
@@ -782,7 +782,7 @@ PHPAPI void php_pcre_match_impl(pcre_cache_entry *pce, char *subject, int subjec
}
/* Add MARK, if available */
if (mark) {
- add_assoc_string(&result_set, "MARK", (char *) mark);
+ add_assoc_string_ex(&result_set, "MARK", sizeof("MARK") - 1, (char *)mark);
}
/* And add it to the output array */
zend_hash_next_index_insert(Z_ARRVAL_P(subpats), &result_set);
@@ -822,7 +822,7 @@ PHPAPI void php_pcre_match_impl(pcre_cache_entry *pce, char *subject, int subjec
}
/* Add MARK, if available */
if (mark) {
- add_assoc_string(subpats, "MARK", (char *) mark);
+ add_assoc_string_ex(subpats, "MARK", sizeof("MARK") - 1, (char *)mark);
}
}
diff --git a/ext/pcre/php_pcre.h b/ext/pcre/php_pcre.h
index fb90395f75..cd6621372f 100644
--- a/ext/pcre/php_pcre.h
+++ b/ext/pcre/php_pcre.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo/pdo.c b/ext/pdo/pdo.c
index 88df420c37..61c68ff46d 100644
--- a/ext/pdo/pdo.c
+++ b/ext/pdo/pdo.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo/pdo_dbh.c b/ext/pdo/pdo_dbh.c
index eb7f940528..aca52ebf20 100644
--- a/ext/pdo/pdo_dbh.c
+++ b/ext/pdo/pdo_dbh.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -425,7 +425,7 @@ static zval *pdo_stmt_instantiate(pdo_dbh_t *dbh, zval *object, zend_class_entry
return object;
} /* }}} */
-static void pdo_stmt_construct(pdo_stmt_t *stmt, zval *object, zend_class_entry *dbstmt_ce, zval *ctor_args TSRMLS_DC) /* {{{ */
+static void pdo_stmt_construct(zend_execute_data *execute_data, pdo_stmt_t *stmt, zval *object, zend_class_entry *dbstmt_ce, zval *ctor_args TSRMLS_DC) /* {{{ */
{
zval query_string;
zval z_key;
@@ -556,7 +556,7 @@ static PHP_METHOD(PDO, prepare)
ZVAL_UNDEF(&stmt->lazy_object_ref);
if (dbh->methods->preparer(dbh, statement, statement_len, stmt, options TSRMLS_CC)) {
- pdo_stmt_construct(stmt, return_value, dbstmt_ce, &ctor_args TSRMLS_CC);
+ pdo_stmt_construct(execute_data, stmt, return_value, dbstmt_ce, &ctor_args TSRMLS_CC);
return;
}
@@ -1109,7 +1109,7 @@ static PHP_METHOD(PDO, query)
stmt->executed = 1;
}
if (ret) {
- pdo_stmt_construct(stmt, return_value, dbh->def_stmt_ce, &dbh->def_stmt_ctor_args TSRMLS_CC);
+ pdo_stmt_construct(execute_data, stmt, return_value, dbh->def_stmt_ce, &dbh->def_stmt_ctor_args TSRMLS_CC);
return;
}
}
diff --git a/ext/pdo/pdo_sql_parser.c b/ext/pdo/pdo_sql_parser.c
index 0db82c6068..9dd7305723 100644
--- a/ext/pdo/pdo_sql_parser.c
+++ b/ext/pdo/pdo_sql_parser.c
@@ -1,7 +1,7 @@
/* Generated by re2c 0.13.5 */
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -406,10 +406,10 @@ yy45:
struct placeholder {
char *pos;
+ char *quoted; /* quoted value */
int len;
int bindno;
int qlen; /* quoted length of value */
- char *quoted; /* quoted value */
int freeq;
struct placeholder *next;
};
diff --git a/ext/pdo/pdo_sql_parser.re b/ext/pdo/pdo_sql_parser.re
index 94ad04b983..79e167ba1d 100644
--- a/ext/pdo/pdo_sql_parser.re
+++ b/ext/pdo/pdo_sql_parser.re
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo/pdo_sqlstate.c b/ext/pdo/pdo_sqlstate.c
index e3585844c6..94829a01a2 100644
--- a/ext/pdo/pdo_sqlstate.c
+++ b/ext/pdo/pdo_sqlstate.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo/pdo_stmt.c b/ext/pdo/pdo_stmt.c
index dd8b01a5b4..5781de78e6 100644
--- a/ext/pdo/pdo_stmt.c
+++ b/ext/pdo/pdo_stmt.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -2267,7 +2267,7 @@ static zend_object *dbstmt_clone_obj(zval *zobject TSRMLS_DC)
}
zend_object_handlers pdo_dbstmt_object_handlers;
-static int pdo_row_serialize(zval *object, unsigned char **buffer, uint32_t *buf_len, zend_serialize_data *data TSRMLS_DC);
+static int pdo_row_serialize(zval *object, unsigned char **buffer, size_t *buf_len, zend_serialize_data *data TSRMLS_DC);
void pdo_stmt_init(TSRMLS_D)
{
@@ -2700,7 +2700,7 @@ zend_object *pdo_row_new(zend_class_entry *ce TSRMLS_DC)
return &row->std;
}
-static int pdo_row_serialize(zval *object, unsigned char **buffer, uint32_t *buf_len, zend_serialize_data *data TSRMLS_DC)
+static int pdo_row_serialize(zval *object, unsigned char **buffer, size_t *buf_len, zend_serialize_data *data TSRMLS_DC)
{
php_error_docref(NULL TSRMLS_CC, E_WARNING, "PDORow instances may not be serialized");
return FAILURE;
diff --git a/ext/pdo/php_pdo.h b/ext/pdo/php_pdo.h
index 0dca85779a..ce5b3a229d 100644
--- a/ext/pdo/php_pdo.h
+++ b/ext/pdo/php_pdo.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo/php_pdo_driver.h b/ext/pdo/php_pdo_driver.h
index 279619ee0d..de9780e226 100644
--- a/ext/pdo/php_pdo_driver.h
+++ b/ext/pdo/php_pdo_driver.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -528,10 +528,10 @@ static inline pdo_dbh_object_t *php_pdo_dbh_fetch_object(zend_object *obj) {
/* describes a column */
struct pdo_column_data {
char *name;
- int namelen;
zend_ulong maxlen;
- enum pdo_param_type param_type;
zend_ulong precision;
+ enum pdo_param_type param_type;
+ int namelen;
/* don't touch this unless your name is dbdo */
void *dbdo_data;
@@ -539,18 +539,21 @@ struct pdo_column_data {
/* describes a bound parameter */
struct pdo_bound_param_data {
+ zval parameter; /* the variable itself */
+
+ zval driver_params; /* optional parameter(s) for the driver */
+
zend_long paramno; /* if -1, then it has a name, and we don't know the index *yet* */
zend_string *name;
zend_long max_value_len; /* as a hint for pre-allocation */
-
- zval parameter; /* the variable itself */
- enum pdo_param_type param_type; /* desired or suggested type */
- zval driver_params; /* optional parameter(s) for the driver */
void *driver_data;
pdo_stmt_t *stmt; /* for convenience in dtor */
+
+ enum pdo_param_type param_type; /* desired or suggested variable type */
+
int is_param; /* parameter or column ? */
};
diff --git a/ext/pdo/php_pdo_error.h b/ext/pdo/php_pdo_error.h
index 60bb89a8f8..e89a2b8811 100644
--- a/ext/pdo/php_pdo_error.h
+++ b/ext/pdo/php_pdo_error.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo/php_pdo_int.h b/ext/pdo/php_pdo_int.h
index 27cca7c29f..23de705ec1 100644
--- a/ext/pdo/php_pdo_int.h
+++ b/ext/pdo/php_pdo_int.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_dblib/dblib_driver.c b/ext/pdo_dblib/dblib_driver.c
index ddf182b190..40d4114879 100644
--- a/ext/pdo_dblib/dblib_driver.c
+++ b/ext/pdo_dblib/dblib_driver.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_dblib/dblib_stmt.c b/ext/pdo_dblib/dblib_stmt.c
index 6bd2a5976e..a29405b24e 100644
--- a/ext/pdo_dblib/dblib_stmt.c
+++ b/ext/pdo_dblib/dblib_stmt.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_dblib/pdo_dblib.c b/ext/pdo_dblib/pdo_dblib.c
index 2801ece8f1..3afd885df5 100644
--- a/ext/pdo_dblib/pdo_dblib.c
+++ b/ext/pdo_dblib/pdo_dblib.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_dblib/php_pdo_dblib.h b/ext/pdo_dblib/php_pdo_dblib.h
index f7de387b96..5198976d25 100644
--- a/ext/pdo_dblib/php_pdo_dblib.h
+++ b/ext/pdo_dblib/php_pdo_dblib.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_dblib/php_pdo_dblib_int.h b/ext/pdo_dblib/php_pdo_dblib_int.h
index df15b229e0..e247b5c19e 100644
--- a/ext/pdo_dblib/php_pdo_dblib_int.h
+++ b/ext/pdo_dblib/php_pdo_dblib_int.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_firebird/firebird_driver.c b/ext/pdo_firebird/firebird_driver.c
index ab4612a119..298d2539e3 100644
--- a/ext/pdo_firebird/firebird_driver.c
+++ b/ext/pdo_firebird/firebird_driver.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_firebird/firebird_statement.c b/ext/pdo_firebird/firebird_statement.c
index 622cbc39a3..d46a67d504 100644
--- a/ext/pdo_firebird/firebird_statement.c
+++ b/ext/pdo_firebird/firebird_statement.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_firebird/pdo_firebird.c b/ext/pdo_firebird/pdo_firebird.c
index 4eea0b69de..4e2c816460 100644
--- a/ext/pdo_firebird/pdo_firebird.c
+++ b/ext/pdo_firebird/pdo_firebird.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_firebird/php_pdo_firebird.h b/ext/pdo_firebird/php_pdo_firebird.h
index f7e9f17f12..3f1fc9a76c 100644
--- a/ext/pdo_firebird/php_pdo_firebird.h
+++ b/ext/pdo_firebird/php_pdo_firebird.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_firebird/php_pdo_firebird_int.h b/ext/pdo_firebird/php_pdo_firebird_int.h
index 1fc610ce78..18670fee18 100644
--- a/ext/pdo_firebird/php_pdo_firebird_int.h
+++ b/ext/pdo_firebird/php_pdo_firebird_int.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_mysql/mysql_driver.c b/ext/pdo_mysql/mysql_driver.c
index 0cf5b55bdd..7e4945a7b8 100644
--- a/ext/pdo_mysql/mysql_driver.c
+++ b/ext/pdo_mysql/mysql_driver.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_mysql/mysql_statement.c b/ext/pdo_mysql/mysql_statement.c
index 5eddc832a1..20d3ede0f6 100644
--- a/ext/pdo_mysql/mysql_statement.c
+++ b/ext/pdo_mysql/mysql_statement.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_mysql/pdo_mysql.c b/ext/pdo_mysql/pdo_mysql.c
index 3a06741a05..d9c04470a4 100644
--- a/ext/pdo_mysql/pdo_mysql.c
+++ b/ext/pdo_mysql/pdo_mysql.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_mysql/php_pdo_mysql.h b/ext/pdo_mysql/php_pdo_mysql.h
index e4d37c88ab..b5f6afd9eb 100644
--- a/ext/pdo_mysql/php_pdo_mysql.h
+++ b/ext/pdo_mysql/php_pdo_mysql.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_mysql/php_pdo_mysql_int.h b/ext/pdo_mysql/php_pdo_mysql_int.h
index 31ccb5d02a..f6cdb0a8f2 100644
--- a/ext/pdo_mysql/php_pdo_mysql_int.h
+++ b/ext/pdo_mysql/php_pdo_mysql_int.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_oci/oci_driver.c b/ext/pdo_oci/oci_driver.c
index a8e7913fa7..9132999461 100644
--- a/ext/pdo_oci/oci_driver.c
+++ b/ext/pdo_oci/oci_driver.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_oci/oci_statement.c b/ext/pdo_oci/oci_statement.c
index 4e341c08be..7c86a23dcc 100644
--- a/ext/pdo_oci/oci_statement.c
+++ b/ext/pdo_oci/oci_statement.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_oci/pdo_oci.c b/ext/pdo_oci/pdo_oci.c
index 8eabb7e7c5..896f392664 100644
--- a/ext/pdo_oci/pdo_oci.c
+++ b/ext/pdo_oci/pdo_oci.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_oci/php_pdo_oci.h b/ext/pdo_oci/php_pdo_oci.h
index 3299dfe269..3448638fc1 100644
--- a/ext/pdo_oci/php_pdo_oci.h
+++ b/ext/pdo_oci/php_pdo_oci.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_oci/php_pdo_oci_int.h b/ext/pdo_oci/php_pdo_oci_int.h
index 4979aadb13..36d45d0af7 100644
--- a/ext/pdo_oci/php_pdo_oci_int.h
+++ b/ext/pdo_oci/php_pdo_oci_int.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_odbc/odbc_driver.c b/ext/pdo_odbc/odbc_driver.c
index e99463de58..c0034d43ea 100644
--- a/ext/pdo_odbc/odbc_driver.c
+++ b/ext/pdo_odbc/odbc_driver.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_odbc/odbc_stmt.c b/ext/pdo_odbc/odbc_stmt.c
index 274ce9b0d6..7491ec685d 100644
--- a/ext/pdo_odbc/odbc_stmt.c
+++ b/ext/pdo_odbc/odbc_stmt.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_odbc/pdo_odbc.c b/ext/pdo_odbc/pdo_odbc.c
index 1fe17c1c30..914b8bc980 100644
--- a/ext/pdo_odbc/pdo_odbc.c
+++ b/ext/pdo_odbc/pdo_odbc.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_odbc/php_pdo_odbc.h b/ext/pdo_odbc/php_pdo_odbc.h
index cd01ae45e5..52e8e6f8e7 100644
--- a/ext/pdo_odbc/php_pdo_odbc.h
+++ b/ext/pdo_odbc/php_pdo_odbc.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_odbc/php_pdo_odbc_int.h b/ext/pdo_odbc/php_pdo_odbc_int.h
index 90d9d5d505..0d6d488b65 100644
--- a/ext/pdo_odbc/php_pdo_odbc_int.h
+++ b/ext/pdo_odbc/php_pdo_odbc_int.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_pgsql/pdo_pgsql.c b/ext/pdo_pgsql/pdo_pgsql.c
index 5fbad7d4a0..5ca4b07a23 100644
--- a/ext/pdo_pgsql/pdo_pgsql.c
+++ b/ext/pdo_pgsql/pdo_pgsql.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_pgsql/pgsql_driver.c b/ext/pdo_pgsql/pgsql_driver.c
index dfc6f4025a..327d70218b 100644
--- a/ext/pdo_pgsql/pgsql_driver.c
+++ b/ext/pdo_pgsql/pgsql_driver.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_pgsql/pgsql_statement.c b/ext/pdo_pgsql/pgsql_statement.c
index 7a315c7f08..05b8f79b27 100644
--- a/ext/pdo_pgsql/pgsql_statement.c
+++ b/ext/pdo_pgsql/pgsql_statement.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_pgsql/php_pdo_pgsql.h b/ext/pdo_pgsql/php_pdo_pgsql.h
index 9c01d9886c..31d89096ad 100644
--- a/ext/pdo_pgsql/php_pdo_pgsql.h
+++ b/ext/pdo_pgsql/php_pdo_pgsql.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_pgsql/php_pdo_pgsql_int.h b/ext/pdo_pgsql/php_pdo_pgsql_int.h
index d6f7ad48aa..722d63706e 100644
--- a/ext/pdo_pgsql/php_pdo_pgsql_int.h
+++ b/ext/pdo_pgsql/php_pdo_pgsql_int.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_pgsql/tests/getnotify.phpt b/ext/pdo_pgsql/tests/getnotify.phpt
index c093e0357a..c54a31604d 100644
--- a/ext/pdo_pgsql/tests/getnotify.phpt
+++ b/ext/pdo_pgsql/tests/getnotify.phpt
@@ -70,14 +70,16 @@ var_dump($db->pgsqlGetNotify());
// Test second parameter, should wait 2 seconds because no notify is queued
$t = microtime(1);
$notify = $db->pgsqlGetNotify(PDO::FETCH_ASSOC, 1000);
-var_dump((microtime(1) - $t) >= 1);
+$diff = microtime(1) - $t;
+var_dump($diff >= 1 || 1 - abs($diff) < .01);
var_dump($notify);
// Test second parameter, should return immediately because a notify is queued
$db->exec("NOTIFY notifies_phpt");
$t = microtime(1);
$notify = $db->pgsqlGetNotify(PDO::FETCH_ASSOC, 5000);
-var_dump((microtime(1) - $t) < 1);
+$diff = microtime(1) - $t;
+var_dump($diff < 1 || abs(1 - abs($diff)) < .01);
var_dump(count($notify));
?>
diff --git a/ext/pdo_sqlite/pdo_sqlite.c b/ext/pdo_sqlite/pdo_sqlite.c
index 33cffee821..0014de4e3b 100644
--- a/ext/pdo_sqlite/pdo_sqlite.c
+++ b/ext/pdo_sqlite/pdo_sqlite.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_sqlite/php_pdo_sqlite.h b/ext/pdo_sqlite/php_pdo_sqlite.h
index 607b3ddedb..9413e1bb70 100644
--- a/ext/pdo_sqlite/php_pdo_sqlite.h
+++ b/ext/pdo_sqlite/php_pdo_sqlite.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_sqlite/php_pdo_sqlite_int.h b/ext/pdo_sqlite/php_pdo_sqlite_int.h
index 188856a3d1..133893bf8f 100644
--- a/ext/pdo_sqlite/php_pdo_sqlite_int.h
+++ b/ext/pdo_sqlite/php_pdo_sqlite_int.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_sqlite/sqlite_driver.c b/ext/pdo_sqlite/sqlite_driver.c
index c76841bae2..413b50b9d4 100644
--- a/ext/pdo_sqlite/sqlite_driver.c
+++ b/ext/pdo_sqlite/sqlite_driver.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pdo_sqlite/sqlite_statement.c b/ext/pdo_sqlite/sqlite_statement.c
index 2cf271c0d3..378d8bb337 100644
--- a/ext/pdo_sqlite/sqlite_statement.c
+++ b/ext/pdo_sqlite/sqlite_statement.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pgsql/pgsql.c b/ext/pgsql/pgsql.c
index e3f64e0ed0..207764b165 100644
--- a/ext/pgsql/pgsql.c
+++ b/ext/pgsql/pgsql.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -35,7 +35,7 @@
#include "php.h"
#include "php_ini.h"
#include "ext/standard/php_standard.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#include "ext/ereg/php_regex.h"
#ifdef PHP_WIN32
# include "win32/time.h"
@@ -5484,26 +5484,26 @@ PHP_PGSQL_API int php_pgsql_meta_data(PGconn *pg_link, const char *table_name, z
char *name;
array_init(&elem);
/* pg_attribute.attnum */
- add_assoc_long(&elem, "num", atoi(PQgetvalue(pg_result,i,1)));
+ add_assoc_long_ex(&elem, "num", sizeof("num") - 1, atoi(PQgetvalue(pg_result, i, 1)));
/* pg_type.typname */
- add_assoc_string(&elem, "type", PQgetvalue(pg_result,i,2));
+ add_assoc_string_ex(&elem, "type", sizeof("type") - 1, PQgetvalue(pg_result, i, 2));
/* pg_attribute.attlen */
- add_assoc_long(&elem, "len", atoi(PQgetvalue(pg_result,i,3)));
+ add_assoc_long_ex(&elem, "len", sizeof("len") - 1, atoi(PQgetvalue(pg_result,i,3)));
/* pg_attribute.attnonull */
- add_assoc_bool(&elem, "not null", !strcmp(PQgetvalue(pg_result,i,4), "t"));
+ add_assoc_bool_ex(&elem, "not null", sizeof("not null") - 1, !strcmp(PQgetvalue(pg_result, i, 4), "t"));
/* pg_attribute.atthasdef */
- add_assoc_bool(&elem, "has default", !strcmp(PQgetvalue(pg_result,i,5), "t"));
+ add_assoc_bool_ex(&elem, "has default", sizeof("has default") - 1, !strcmp(PQgetvalue(pg_result,i,5), "t"));
/* pg_attribute.attndims */
- add_assoc_long(&elem, "array dims", atoi(PQgetvalue(pg_result,i,6)));
+ add_assoc_long_ex(&elem, "array dims", sizeof("array dims") - 1, atoi(PQgetvalue(pg_result, i, 6)));
/* pg_type.typtype */
- add_assoc_bool(&elem, "is enum", !strcmp(PQgetvalue(pg_result,i,7), "e"));
+ add_assoc_bool_ex(&elem, "is enum", sizeof("is enum") - 1, !strcmp(PQgetvalue(pg_result, i, 7), "e"));
if (extended) {
/* pg_type.typtype */
- add_assoc_bool(&elem, "is base", !strcmp(PQgetvalue(pg_result,i,7), "b"));
- add_assoc_bool(&elem, "is composite", !strcmp(PQgetvalue(pg_result,i,7), "c"));
- add_assoc_bool(&elem, "is pesudo", !strcmp(PQgetvalue(pg_result,i,7), "p"));
+ add_assoc_bool_ex(&elem, "is base", sizeof("is base") - 1, !strcmp(PQgetvalue(pg_result, i, 7), "b"));
+ add_assoc_bool_ex(&elem, "is composite", sizeof("is composite") - 1, !strcmp(PQgetvalue(pg_result, i, 7), "c"));
+ add_assoc_bool_ex(&elem, "is pesudo", sizeof("is pesudo") - 1, !strcmp(PQgetvalue(pg_result, i, 7), "p"));
/* pg_description.description */
- add_assoc_string(&elem, "description", PQgetvalue(pg_result,i,8));
+ add_assoc_string_ex(&elem, "description", sizeof("description") - 1, PQgetvalue(pg_result, i, 8));
}
/* pg_attribute.attname */
name = PQgetvalue(pg_result,i,0);
@@ -5701,7 +5701,7 @@ static int php_pgsql_add_quotes(zval *src, zend_bool should_free TSRMLS_DC)
if (should_free) {
zval_ptr_dtor(src);
}
- ZVAL_STR(src, str.s);
+ ZVAL_NEW_STR(src, str.s);
return SUCCESS;
}
@@ -5971,7 +5971,7 @@ PHP_PGSQL_API int php_pgsql_convert(PGconn *pg_link, const char *table_name, con
/* better to use PGSQLescapeLiteral since PGescapeStringConn does not handle special \ */
str->len = PQescapeStringConn(pg_link, str->val, Z_STRVAL_P(val), Z_STRLEN_P(val), NULL);
str = zend_string_realloc(str, str->len, 0);
- ZVAL_STR(&new_val, str);
+ ZVAL_NEW_STR(&new_val, str);
php_pgsql_add_quotes(&new_val, 1 TSRMLS_CC);
}
break;
@@ -6268,7 +6268,7 @@ PHP_PGSQL_API int php_pgsql_convert(PGconn *pg_link, const char *table_name, con
smart_str_appendl(&s, Z_STRVAL(new_val), Z_STRLEN(new_val));
smart_str_0(&s);
zval_ptr_dtor(&new_val);
- ZVAL_STR(&new_val, s.s);
+ ZVAL_NEW_STR(&new_val, s.s);
}
break;
diff --git a/ext/pgsql/pgsql.dsp b/ext/pgsql/pgsql.dsp
deleted file mode 100644
index 098469f36d..0000000000
--- a/ext/pgsql/pgsql.dsp
+++ /dev/null
@@ -1,167 +0,0 @@
-# Microsoft Developer Studio Project File - Name="pgsql" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=pgsql - Win32 Debug_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "pgsql.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "pgsql.mak" CFG="pgsql - Win32 Debug_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "pgsql - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "pgsql - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "pgsql - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "pgsql - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "pgsql - Win32 Release"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release"
-# PROP BASE Intermediate_Dir "Release"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release"
-# PROP Intermediate_Dir "Release"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "PGSQL_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\..\..\php_build\include\pgsql" /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /D "NDEBUG" /D ZEND_DEBUG=0 /D "PGSQL_EXPORTS" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ZEND_WIN32" /D "PHP_WIN32" /D "COMPILE_DL_PGSQL" /D HAVE_PGSQL=1 /D "HAVE_PQCMDTUPLES" /D "HAVE_PQCLIENTENCODING" /D "HAVE_PQESCAPE" /D "HAVE_PG_CONFIG_H" /FD /c
-# SUBTRACT CPP /YX
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib ws2_32.lib libpqdll.lib php5ts.lib /nologo /dll /machine:I386 /nodefaultlib:"msvcrt.lib" /out:"../../Release/pgsql.dll" /libpath:"..\..\..\PostgreSQL\lib" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-
-!ELSEIF "$(CFG)" == "pgsql - Win32 Debug"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug"
-# PROP BASE Intermediate_Dir "Debug"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug"
-# PROP Intermediate_Dir "Debug"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "PGSQL_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "..\..\..\php_build\include\pgsql" /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /D "_DEBUG" /D ZEND_DEBUG=1 /D "PGSQL_EXPORTS" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ZEND_WIN32" /D "PHP_WIN32" /D "COMPILE_DL_PGSQL" /D HAVE_PGSQL=1 /D "HAVE_PQCMDTUPLES" /D "HAVE_PQCLIENTENCODING" /D "HAVE_PQESCAPE" /D "HAVE_PG_CONFIG_H" /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /nodefaultlib:"msvcrtd.lib" /out:"../../Debug/pgsql.dll" /pdbtype:sept
-
-!ELSEIF "$(CFG)" == "pgsql - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\..\PostgreSQL\include" /I "..\..\..\bindlib_w32" /D "NDEBUG" /D "ZTS" /D "PGSQL_EXPORTS" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ZEND_WIN32" /D "PHP_WIN32" /D "COMPILE_DL_PGSQL" /D HAVE_PGSQL=1 /D ZTS=1 /FD /c
-# SUBTRACT BASE CPP /YX
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\..\..\php_build\include\pgsql" /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /D "NDEBUG" /D "ZTS" /D ZEND_DEBUG=0 /D "PGSQL_EXPORTS" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ZEND_WIN32" /D "PHP_WIN32" /D "COMPILE_DL_PGSQL" /D HAVE_PGSQL=1 /D "HAVE_PQCMDTUPLES" /D "HAVE_PQCLIENTENCODING" /D "HAVE_PQESCAPE" /D "HAVE_PG_CONFIG_H" /FR /FD /c
-# SUBTRACT CPP /YX
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib ws2_32.lib libpqdll.lib php5ts.lib /nologo /dll /machine:I386 /libpath:"..\..\..\PostgreSQL\lib" /libpath:"..\..\Release_TS"
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib ws2_32.lib libpq.lib php5ts.lib /nologo /dll /machine:I386 /out:"../../Release_TS/php_pgsql.dll" /libpath:"..\..\..\php_build\postgresql\src\interfaces\libpq\Release" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-
-!ELSEIF "$(CFG)" == "pgsql - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "_DEBUG" /D "PGSQL_EXPORTS" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ZEND_WIN32" /D "PHP_WIN32" /D "COMPILE_DL_PGSQL" /D HAVE_PGSQL=1 /D ZTS=1 /YX /FD /GZ /c
-# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "..\..\..\php_build\include\pgsql" /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /D "_DEBUG" /D "ZTS" /D ZEND_DEBUG=1 /D "PGSQL_EXPORTS" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ZEND_WIN32" /D "PHP_WIN32" /D "COMPILE_DL_PGSQL" /D HAVE_PGSQL=1 /D "HAVE_PQCMDTUPLES" /D "HAVE_PQCLIENTENCODING" /D "HAVE_PQESCAPE" /D "HAVE_PG_CONFIG_H" /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib libpq.lib /nologo /dll /debug /machine:I386 /out:"../../Debug_TS/pgsql.dll" /pdbtype:sept
-
-!ENDIF
-
-# Begin Target
-
-# Name "pgsql - Win32 Release"
-# Name "pgsql - Win32 Debug"
-# Name "pgsql - Win32 Release_TS"
-# Name "pgsql - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\pgsql.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_pgsql.h
-# End Source File
-# End Group
-# End Target
-# End Project
diff --git a/ext/pgsql/php_pgsql.h b/ext/pgsql/php_pgsql.h
index 9bfbf142f9..661c02f77f 100644
--- a/ext/pgsql/php_pgsql.h
+++ b/ext/pgsql/php_pgsql.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/phar/phar.c b/ext/phar/phar.c
index 4c02e1aecf..8f17c771d1 100644
--- a/ext/phar/phar.c
+++ b/ext/phar/phar.c
@@ -1618,7 +1618,7 @@ static int phar_open_from_fp(php_stream* fp, char *fname, int fname_len, char *a
#ifndef MAX_WBITS
#define MAX_WBITS 15
#endif
- add_assoc_long(&filterparams, "window", MAX_WBITS + 32);
+ add_assoc_long_ex(&filterparams, "window", sizeof("window") - 1, MAX_WBITS + 32);
/* entire file is gzip-compressed, uncompress to temporary file */
if (!(temp = php_stream_fopen_tmpfile())) {
@@ -1630,7 +1630,7 @@ static int phar_open_from_fp(php_stream* fp, char *fname, int fname_len, char *a
if (!filter) {
err = 1;
- add_assoc_long(&filterparams, "window", MAX_WBITS);
+ add_assoc_long_ex(&filterparams, "window", sizeof("window") - 1, MAX_WBITS);
filter = php_stream_filter_create("zlib.inflate", &filterparams, php_stream_is_persistent(fp) TSRMLS_CC);
zval_dtor(&filterparams);
diff --git a/ext/phar/phar_internal.h b/ext/phar/phar_internal.h
index 77df0a71c2..f49143bc8c 100644
--- a/ext/phar/phar_internal.h
+++ b/ext/phar/phar_internal.h
@@ -35,6 +35,7 @@
#include "zend_operators.h"
#include "zend_qsort.h"
#include "zend_vm.h"
+#include "zend_smart_str.h"
#include "main/php_streams.h"
#include "main/streams/php_stream_plain_wrapper.h"
#include "main/SAPI.h"
@@ -49,7 +50,6 @@
#include "ext/standard/md5.h"
#include "ext/standard/sha1.h"
#include "ext/standard/php_var.h"
-#include "ext/standard/php_smart_str.h"
#include "ext/standard/php_versioning.h"
#ifndef PHP_WIN32
#include "TSRM/tsrm_strtok_r.h"
diff --git a/ext/phar/phar_object.c b/ext/phar/phar_object.c
index ed3e60a0ea..f82b825631 100755
--- a/ext/phar/phar_object.c
+++ b/ext/phar/phar_object.c
@@ -87,7 +87,7 @@ static void phar_mung_server_vars(char *fname, char *entry, int entry_len, char
zend_string *str = strpprintf(4096, "phar://%s%s", fname, entry);
ZVAL_STR(&temp, Z_STR_P(stuff));
- ZVAL_STR(stuff, str);
+ ZVAL_NEW_STR(stuff, str);
zend_hash_str_update(_SERVER, "PHAR_PATH_TRANSLATED", sizeof("PHAR_PATH_TRANSLATED")-1, &temp);
}
@@ -134,7 +134,7 @@ static void phar_mung_server_vars(char *fname, char *entry, int entry_len, char
zend_string *str = strpprintf(4096, "phar://%s%s", fname, entry);
ZVAL_STR(&temp, Z_STR_P(stuff));
- ZVAL_STR(stuff, str);
+ ZVAL_NEW_STR(stuff, str);
zend_hash_str_update(_SERVER, "PHAR_SCRIPT_FILENAME", sizeof("PHAR_SCRIPT_FILENAME")-1, &temp);
}
@@ -553,6 +553,7 @@ PHP_METHOD(Phar, webPhar)
int entry_len, code, not_cgi;
phar_archive_data *phar = NULL;
phar_entry_info *info = NULL;
+ size_t sapi_mod_name_len = strlen(sapi_module.name);
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|s!s!saz", &alias, &alias_len, &index_php, &index_php_len, &f404, &f404_len, &mimeoverride, &rewrite) == FAILURE) {
return;
@@ -587,9 +588,9 @@ PHP_METHOD(Phar, webPhar)
++basename;
}
- if ((strlen(sapi_module.name) == sizeof("cgi-fcgi")-1 && !strncmp(sapi_module.name, "cgi-fcgi", sizeof("cgi-fcgi")-1))
- || (strlen(sapi_module.name) == sizeof("fpm-fcgi")-1 && !strncmp(sapi_module.name, "fpm-fcgi", sizeof("fpm-fcgi")-1))
- || (strlen(sapi_module.name) == sizeof("cgi")-1 && !strncmp(sapi_module.name, "cgi", sizeof("cgi")-1))) {
+ if ((sapi_mod_name_len == sizeof("cgi-fcgi") - 1 && !strncmp(sapi_module.name, "cgi-fcgi", sizeof("cgi-fcgi") - 1))
+ || (sapi_mod_name_len == sizeof("fpm-fcgi") - 1 && !strncmp(sapi_module.name, "fpm-fcgi", sizeof("fpm-fcgi") - 1))
+ || (sapi_mod_name_len == sizeof("cgi") - 1 && !strncmp(sapi_module.name, "cgi", sizeof("cgi") - 1))) {
if (Z_TYPE(PG(http_globals)[TRACK_VARS_SERVER]) != IS_UNDEF) {
HashTable *_server = Z_ARRVAL(PG(http_globals)[TRACK_VARS_SERVER]);
@@ -1382,10 +1383,10 @@ struct _phar_t {
phar_archive_object *p;
zend_class_entry *c;
char *b;
- uint l;
zval *ret;
- int count;
php_stream *fp;
+ uint l;
+ int count;
};
static int phar_build(zend_object_iterator *iter, void *puser TSRMLS_DC) /* {{{ */
@@ -3550,7 +3551,7 @@ PHP_METHOD(Phar, offsetGet)
}
sfname = strpprintf(0, "phar://%s/%s", phar_obj->archive->fname, fname);
- ZVAL_STR(&zfname, sfname);
+ ZVAL_NEW_STR(&zfname, sfname);
spl_instantiate_arg_ex1(phar_obj->spl.info_class, return_value, &zfname TSRMLS_CC);
zval_ptr_dtor(&zfname);
}
diff --git a/ext/phar/tar.c b/ext/phar/tar.c
index 985abd14a9..76862f7cdb 100644
--- a/ext/phar/tar.c
+++ b/ext/phar/tar.c
@@ -570,7 +570,7 @@ bail:
phar_destroy_phar_data(myphar TSRMLS_CC);
return FAILURE;
}
- } while (read != 0);
+ } while (!php_stream_eof(fp));
if (zend_hash_str_exists(&(myphar->manifest), ".phar/stub.php", sizeof(".phar/stub.php")-1)) {
myphar->is_data = 0;
diff --git a/ext/phar/zip.c b/ext/phar/zip.c
index a314498813..4fe0bf05c8 100644
--- a/ext/phar/zip.c
+++ b/ext/phar/zip.c
@@ -241,7 +241,7 @@ int phar_parse_zipfile(php_stream *fp, char *fname, int fname_len, char *alias,
mydata->metadata_len = 0;
/* if not valid serialized data, it is a regular string */
- ZVAL_STR(&mydata->metadata, zend_string_init(metadata, PHAR_GET_16(locator.comment_len), mydata->is_persistent));
+ ZVAL_NEW_STR(&mydata->metadata, zend_string_init(metadata, PHAR_GET_16(locator.comment_len), mydata->is_persistent));
}
} else {
ZVAL_UNDEF(&mydata->metadata);
@@ -529,7 +529,7 @@ foundit:
entry.metadata_len = 0;
/* if not valid serialized data, it is a regular string */
- ZVAL_STR(&entry.metadata, zend_string_init(buf, PHAR_GET_16(zipentry.comment_len), entry.is_persistent));
+ ZVAL_NEW_STR(&entry.metadata, zend_string_init(buf, PHAR_GET_16(zipentry.comment_len), entry.is_persistent));
}
} else {
ZVAL_UNDEF(&entry.metadata);
diff --git a/ext/posix/php_posix.h b/ext/posix/php_posix.h
index 8ace07c1c0..ebd449231d 100644
--- a/ext/posix/php_posix.h
+++ b/ext/posix/php_posix.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/posix/posix.c b/ext/posix/posix.c
index 091b42cfdd..ca7d34c645 100644
--- a/ext/posix/posix.c
+++ b/ext/posix/posix.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pspell/php_pspell.h b/ext/pspell/php_pspell.h
index 83103fae74..bd0956c2ba 100644
--- a/ext/pspell/php_pspell.h
+++ b/ext/pspell/php_pspell.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pspell/pspell.c b/ext/pspell/pspell.c
index bf01f28df6..72165ae78e 100644
--- a/ext/pspell/pspell.c
+++ b/ext/pspell/pspell.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/pspell/pspell.dsp b/ext/pspell/pspell.dsp
deleted file mode 100644
index f310099d89..0000000000
--- a/ext/pspell/pspell.dsp
+++ /dev/null
@@ -1,112 +0,0 @@
-# Microsoft Developer Studio Project File - Name="pspell" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=pspell - Win32 Debug_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "pspell.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "pspell.mak" CFG="pspell - Win32 Debug_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "pspell - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "pspell - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "pspell - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "pspell___Win32_Debug_TS"
-# PROP BASE Intermediate_Dir "pspell___Win32_Debug_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\zlib" /I "..\..\TSRM" /D ZEND_DEBUG=1 /D "WIN32" /D "ZEND_WIN32" /D "PHP_WIN32" /D "_WINDOWS" /YX /FD /GZ /c
-# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\zlib" /I "..\..\TSRM" /I "..\..\..\aspell\include\pspell" /I "..\..\..\php_build\include\pspell." /D ZEND_DEBUG=1 /D "_DEBUG" /D ZTS=1 /D HAVE_PSPELL=1 /D "COMPILE_DL_PSPELL" /D "WIN32" /D "ZEND_WIN32" /D "PHP_WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "PSPELL_EXPORTS" /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 php5ts_debug.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_pspell.dll" /pdbtype:sept /libpath:"..\..\Debug_TS"
-# ADD LINK32 php5ts_debug.lib aspell-15.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_pspell.dll" /pdbtype:sept /libpath:"..\..\Debug_TS" /libpath:"..\..\..\aspell\lib"
-
-!ELSEIF "$(CFG)" == "pspell - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "pspell___Win32_Release_TS"
-# PROP BASE Intermediate_Dir "pspell___Win32_Release_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "PSPELL_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\zlib" /I "..\..\TSRM" /I "..\..\..\aspell\include\pspell" /I "..\..\..\php_build\include\pspell" /D ZEND_DEBUG=0 /D "NDEBUG" /D ZTS=1 /D HAVE_PSPELL=1 /D "COMPILE_DL_PSPELL" /D "WIN32" /D "ZEND_WIN32" /D "PHP_WIN32" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "PSPELL_EXPORTS" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 php5ts.lib aspell-15.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_pspell.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\..\aspell\lib"
-
-!ENDIF
-
-# Begin Target
-
-# Name "pspell - Win32 Debug_TS"
-# Name "pspell - Win32 Release_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\pspell.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_pspell.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# End Target
-# End Project
diff --git a/ext/readline/php_readline.h b/ext/readline/php_readline.h
index 5660bdb7f6..7a014164fc 100644
--- a/ext/readline/php_readline.h
+++ b/ext/readline/php_readline.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/readline/readline.c b/ext/readline/readline.c
index 5299f839dc..0e7b146174 100644
--- a/ext/readline/readline.c
+++ b/ext/readline/readline.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/readline/readline_cli.c b/ext/readline/readline_cli.c
index c7fb0438e9..ff0671ce9f 100644
--- a/ext/readline/readline_cli.c
+++ b/ext/readline/readline_cli.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -42,7 +42,7 @@
#include "php_main.h"
#include "fopen_wrappers.h"
#include "ext/standard/php_standard.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#ifdef __riscos__
#include <unixlib/local.h>
diff --git a/ext/readline/readline_cli.h b/ext/readline/readline_cli.h
index becd9d3342..6e57c83408 100644
--- a/ext/readline/readline_cli.h
+++ b/ext/readline/readline_cli.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -20,7 +20,7 @@
/* $Id$ */
#include "php.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str_public.h"
ZEND_BEGIN_MODULE_GLOBALS(cli_readline)
char *pager;
diff --git a/ext/recode/php_recode.h b/ext/recode/php_recode.h
index 76ae292c56..265af7f148 100644
--- a/ext/recode/php_recode.h
+++ b/ext/recode/php_recode.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/recode/recode.c b/ext/recode/recode.c
index 2e044301cb..a70a4fcb2c 100644
--- a/ext/recode/recode.c
+++ b/ext/recode/recode.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c
index ad6a2fb841..fc279e2d12 100644
--- a/ext/reflection/php_reflection.c
+++ b/ext/reflection/php_reflection.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -83,7 +83,7 @@ ZEND_DECLARE_MODULE_GLOBALS(reflection)
/* Method macros */
#define METHOD_NOTSTATIC(ce) \
- if (!Z_OBJ(EG(This)) || !instanceof_function(Z_OBJCE(EG(This)), ce TSRMLS_CC)) { \
+ if (!Z_OBJ(EX(This)) || !instanceof_function(Z_OBJCE(EX(This)), ce TSRMLS_CC)) { \
php_error_docref(NULL TSRMLS_CC, E_ERROR, "%s() cannot be called statically", get_active_function_name(TSRMLS_C)); \
return; \
} \
@@ -209,10 +209,10 @@ typedef enum {
/* Struct for reflection objects */
typedef struct {
zval dummy; /* holder for the second property */
- void *ptr;
- reflection_type_t ref_type;
zval obj;
+ void *ptr;
zend_class_entry *ce;
+ reflection_type_t ref_type;
unsigned int ignore_visibility:1;
zend_object zo;
} reflection_object;
@@ -941,7 +941,7 @@ static void _property_string(string *str, zend_property_info *prop, char *prop_n
string_printf(str, "static ");
}
- zend_unmangle_property_name(prop->name->val, prop->name->len, &class_name, (const char**)&prop_name);
+ zend_unmangle_property_name(prop->name, &class_name, (const char**)&prop_name);
string_printf(str, "$%s", prop_name);
}
@@ -995,9 +995,12 @@ static int _extension_class_string(zval *el TSRMLS_DC, int num_args, va_list arg
int *num_classes = va_arg(args, int*);
if ((ce->type == ZEND_INTERNAL_CLASS) && ce->info.internal.module && !strcasecmp(ce->info.internal.module->name, module->name)) {
- string_printf(str, "\n");
- _class_string(str, ce, NULL, indent TSRMLS_CC);
- (*num_classes)++;
+ /* dump class if it is not an alias */
+ if (!zend_binary_strcasecmp(ce->name->val, ce->name->len, hash_key->key->val, hash_key->key->len)) {
+ string_printf(str, "\n");
+ _class_string(str, ce, NULL, indent TSRMLS_CC);
+ (*num_classes)++;
+ }
}
return ZEND_HASH_APPLY_KEEP;
}
@@ -1178,7 +1181,7 @@ PHPAPI void zend_reflection_class_factory(zend_class_entry *ce, zval *object TSR
reflection_object *intern;
zval name;
- ZVAL_STR(&name, zend_string_copy(ce->name));
+ ZVAL_STR_COPY(&name, ce->name);
reflection_instantiate(reflection_class_ptr, object TSRMLS_CC);
intern = Z_REFLECTION_P(object);
intern->ptr = ce;
@@ -1251,7 +1254,7 @@ static void reflection_function_factory(zend_function *function, zval *closure_o
reflection_object *intern;
zval name;
- ZVAL_STR(&name, zend_string_copy(function->common.function_name));
+ ZVAL_STR_COPY(&name, function->common.function_name);
reflection_instantiate(reflection_function_ptr, object TSRMLS_CC);
intern = Z_REFLECTION_P(object);
@@ -1273,9 +1276,9 @@ static void reflection_method_factory(zend_class_entry *ce, zend_function *metho
zval name;
zval classname;
- ZVAL_STR(&name, zend_string_copy((method->common.scope && method->common.scope->trait_aliases)?
- zend_resolve_method_name(ce, method) : method->common.function_name));
- ZVAL_STR(&classname, zend_string_copy(method->common.scope->name));
+ ZVAL_STR_COPY(&name, (method->common.scope && method->common.scope->trait_aliases)?
+ zend_resolve_method_name(ce, method) : method->common.function_name);
+ ZVAL_STR_COPY(&classname, method->common.scope->name);
reflection_instantiate(reflection_method_ptr, object TSRMLS_CC);
intern = Z_REFLECTION_P(object);
intern->ptr = method;
@@ -1298,15 +1301,16 @@ static void reflection_property_factory(zend_class_entry *ce, zend_property_info
zval classname;
property_reference *reference;
const char *class_name, *prop_name;
+ size_t prop_name_len;
- zend_unmangle_property_name(prop->name->val, prop->name->len, &class_name, &prop_name);
+ zend_unmangle_property_name_ex(prop->name, &class_name, &prop_name, &prop_name_len);
if (!(prop->flags & ZEND_ACC_PRIVATE)) {
/* we have to search the class hierarchy for this (implicit) public or protected property */
zend_class_entry *tmp_ce = ce, *store_ce = ce;
zend_property_info *tmp_info = NULL;
- while (tmp_ce && (tmp_info = zend_hash_str_find_ptr(&tmp_ce->properties_info, prop_name, strlen(prop_name))) == NULL) {
+ while (tmp_ce && (tmp_info = zend_hash_str_find_ptr(&tmp_ce->properties_info, prop_name, prop_name_len)) == NULL) {
ce = tmp_ce;
tmp_ce = tmp_ce->parent;
}
@@ -1318,8 +1322,8 @@ static void reflection_property_factory(zend_class_entry *ce, zend_property_info
}
}
- ZVAL_STRING(&name, prop_name);
- ZVAL_STR(&classname, zend_string_copy(prop->ce->name));
+ ZVAL_STRINGL(&name, prop_name, prop_name_len);
+ ZVAL_STR_COPY(&classname, prop->ce->name);
reflection_instantiate(reflection_property_ptr, object TSRMLS_CC);
intern = Z_REFLECTION_P(object);
@@ -1622,7 +1626,7 @@ ZEND_METHOD(reflection_function, __construct)
return;
}
- ZVAL_STR(&name, zend_string_copy(fptr->common.function_name));
+ ZVAL_STR_COPY(&name, fptr->common.function_name);
reflection_update_property(object, "name", &name);
intern->ptr = fptr;
intern->ref_type = REF_TYPE_FUNCTION;
@@ -2739,9 +2743,9 @@ ZEND_METHOD(reflection_method, __construct)
}
efree(lcname);
- ZVAL_STR(&name, zend_string_copy(mptr->common.scope->name));
+ ZVAL_STR_COPY(&name, mptr->common.scope->name);
reflection_update_property(object, "class", &name);
- ZVAL_STR(&name, zend_string_copy(mptr->common.function_name));
+ ZVAL_STR_COPY(&name, mptr->common.function_name);
reflection_update_property(object, "name", &name);
intern->ptr = mptr;
intern->ref_type = REF_TYPE_FUNCTION;
@@ -3304,7 +3308,7 @@ static void reflection_class_object_ctor(INTERNAL_FUNCTION_PARAMETERS, int is_ob
}
if (Z_TYPE_P(argument) == IS_OBJECT) {
- ZVAL_STR(&classname, zend_string_copy(Z_OBJCE_P(argument)->name));
+ ZVAL_STR_COPY(&classname, Z_OBJCE_P(argument)->name);
reflection_update_property(object, "name", &classname);
intern->ptr = Z_OBJCE_P(argument);
if (is_object) {
@@ -3320,7 +3324,7 @@ static void reflection_class_object_ctor(INTERNAL_FUNCTION_PARAMETERS, int is_ob
return;
}
- ZVAL_STR(&classname, zend_string_copy(ce->name));
+ ZVAL_STR_COPY(&classname, ce->name);
reflection_update_property(object, "name", &classname);
intern->ptr = ce;
@@ -3794,7 +3798,7 @@ ZEND_METHOD(reflection_class, hasProperty)
RETURN_TRUE;
} else {
if (Z_TYPE(intern->obj) != IS_UNDEF && Z_OBJ_HANDLER(intern->obj, has_property)) {
- ZVAL_STR(&property, zend_string_copy(name));
+ ZVAL_STR_COPY(&property, name);
if (Z_OBJ_HANDLER(intern->obj, has_property)(&intern->obj, &property, 2, NULL TSRMLS_CC)) {
zval_ptr_dtor(&property);
RETURN_TRUE;
@@ -3905,7 +3909,7 @@ static int _adddynproperty(zval *ptr TSRMLS_DC, int num_args, va_list args, zend
{
zval property;
zend_class_entry *ce = *va_arg(args, zend_class_entry**);
- zval *retval = va_arg(args, zval*), member;
+ zval *retval = va_arg(args, zval*);
/* under some circumstances, the properties hash table may contain numeric
* properties (e.g. when casting from array). This is a WONT FIX bug, at
@@ -3918,8 +3922,7 @@ static int _adddynproperty(zval *ptr TSRMLS_DC, int num_args, va_list args, zend
return 0; /* non public cannot be dynamic */
}
- ZVAL_STR(&member, hash_key->key);
- if (zend_get_property_info(ce, &member, 1 TSRMLS_CC) == &EG(std_property_info)) {
+ if (zend_get_property_info(ce, hash_key->key, 1 TSRMLS_CC) == &EG(std_property_info)) {
EG(std_property_info).flags = ZEND_ACC_IMPLICIT_PUBLIC;
reflection_property_factory(ce, &EG(std_property_info), &property TSRMLS_CC);
add_next_index_zval(retval, &property);
@@ -4733,7 +4736,6 @@ ZEND_METHOD(reflection_property, __construct)
{
zval propname, cname, *classname;
char *name_str;
- const char *class_name, *prop_name;
size_t name_len;
int dynam_prop = 0;
zval *object;
@@ -4797,11 +4799,13 @@ ZEND_METHOD(reflection_property, __construct)
}
if (dynam_prop == 0) {
- zend_unmangle_property_name(property_info->name->val, property_info->name->len, &class_name, &prop_name);
- ZVAL_STR(&cname, zend_string_copy(property_info->ce->name));
- ZVAL_STRING(&propname, prop_name);
+ const char *class_name, *prop_name;
+ size_t prop_name_len;
+ zend_unmangle_property_name_ex(property_info->name, &class_name, &prop_name, &prop_name_len);
+ ZVAL_STR_COPY(&cname, property_info->ce->name);
+ ZVAL_STRINGL(&propname, prop_name, prop_name_len);
} else {
- ZVAL_STR(&cname, zend_string_copy(ce->name));
+ ZVAL_STR_COPY(&cname, ce->name);
ZVAL_STRINGL(&propname, name_str, name_len);
}
reflection_update_property(object, "class", &cname);
@@ -4950,12 +4954,14 @@ ZEND_METHOD(reflection_property, getValue)
ZVAL_DUP(return_value, &CE_STATIC_MEMBERS(intern->ce)[ref->prop.offset]);
} else {
const char *class_name, *prop_name;
+ size_t prop_name_len;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "o", &object) == FAILURE) {
return;
}
- zend_unmangle_property_name(ref->prop.name->val, ref->prop.name->len, &class_name, &prop_name);
- member_p = zend_read_property(ref->ce, object, prop_name, strlen(prop_name), 1 TSRMLS_CC);
+
+ zend_unmangle_property_name_ex(ref->prop.name, &class_name, &prop_name, &prop_name_len);
+ member_p = zend_read_property(ref->ce, object, prop_name, prop_name_len, 1 TSRMLS_CC);
ZVAL_DUP(return_value, member_p);
}
}
@@ -5024,12 +5030,14 @@ ZEND_METHOD(reflection_property, setValue)
}
} else {
const char *class_name, *prop_name;
+ size_t prop_name_len;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "oz", &object, &value) == FAILURE) {
return;
}
- zend_unmangle_property_name(ref->prop.name->val, ref->prop.name->len, &class_name, &prop_name);
- zend_update_property(ref->ce, object, prop_name, strlen(prop_name), value TSRMLS_CC);
+
+ zend_unmangle_property_name_ex(ref->prop.name, &class_name, &prop_name, &prop_name_len);
+ zend_update_property(ref->ce, object, prop_name, prop_name_len, value TSRMLS_CC);
}
}
/* }}} */
@@ -5043,18 +5051,17 @@ ZEND_METHOD(reflection_property, getDeclaringClass)
zend_class_entry *tmp_ce, *ce;
zend_property_info *tmp_info;
const char *prop_name, *class_name;
- int prop_name_len;
+ size_t prop_name_len;
if (zend_parse_parameters_none() == FAILURE) {
return;
}
GET_REFLECTION_OBJECT_PTR(ref);
- if (zend_unmangle_property_name(ref->prop.name->val, ref->prop.name->len, &class_name, &prop_name) != SUCCESS) {
+ if (zend_unmangle_property_name_ex(ref->prop.name, &class_name, &prop_name, &prop_name_len) != SUCCESS) {
RETURN_FALSE;
}
- prop_name_len = strlen(prop_name);
ce = tmp_ce = ref->ce;
while (tmp_ce && (tmp_info = zend_hash_str_find_ptr(&tmp_ce->properties_info, prop_name, prop_name_len)) != NULL) {
if (tmp_info->flags & ZEND_ACC_PRIVATE || tmp_info->flags & ZEND_ACC_SHADOW) {
@@ -5280,7 +5287,7 @@ static int _addinientry(zval *el TSRMLS_DC, int num_args, va_list args, zend_has
if (ini_entry->value) {
zval zv;
- ZVAL_STR(&zv, zend_string_copy(ini_entry->value));
+ ZVAL_STR_COPY(&zv, ini_entry->value);
zend_symtable_update(Z_ARRVAL_P(retval), ini_entry->name, &zv);
} else {
zend_symtable_update(Z_ARRVAL_P(retval), ini_entry->name, &EG(uninitialized_zval));
@@ -5316,11 +5323,20 @@ static int add_extension_class(zval *zv TSRMLS_DC, int num_args, va_list args, z
int add_reflection_class = va_arg(args, int);
if ((ce->type == ZEND_INTERNAL_CLASS) && ce->info.internal.module && !strcasecmp(ce->info.internal.module->name, module->name)) {
+ zend_string *name;
+
+ if (zend_binary_strcasecmp(ce->name->val, ce->name->len, hash_key->key->val, hash_key->key->len)) {
+ /* This is an class alias, use alias name */
+ name = hash_key->key;
+ } else {
+ /* Use class name */
+ name = ce->name;
+ }
if (add_reflection_class) {
zend_reflection_class_factory(ce, &zclass TSRMLS_CC);
- zend_hash_update(Z_ARRVAL_P(class_array), ce->name, &zclass);
+ zend_hash_update(Z_ARRVAL_P(class_array), name, &zclass);
} else {
- add_next_index_str(class_array, zend_string_copy(ce->name));
+ add_next_index_str(class_array, zend_string_copy(name));
}
}
return ZEND_HASH_APPLY_KEEP;
diff --git a/ext/reflection/php_reflection.h b/ext/reflection/php_reflection.h
index 2c03bd6e7e..1c436d7dcc 100644
--- a/ext/reflection/php_reflection.h
+++ b/ext/reflection/php_reflection.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/session/mod_files.c b/ext/session/mod_files.c
index bc87ef9e1e..cb61c8a221 100644
--- a/ext/session/mod_files.c
+++ b/ext/session/mod_files.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -57,13 +57,13 @@
#endif
typedef struct {
- int fd;
char *lastkey;
char *basedir;
size_t basedir_len;
size_t dirdepth;
size_t st_size;
int filemode;
+ int fd;
} ps_files;
ps_module ps_mod_files = {
diff --git a/ext/session/mod_files.h b/ext/session/mod_files.h
index d1d26cd39b..a56dce1d36 100644
--- a/ext/session/mod_files.h
+++ b/ext/session/mod_files.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/session/mod_mm.c b/ext/session/mod_mm.c
index 319f1d3c79..bf48436a7e 100644
--- a/ext/session/mod_mm.c
+++ b/ext/session/mod_mm.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/session/mod_mm.h b/ext/session/mod_mm.h
index cafbfa0932..e0f2c1239f 100644
--- a/ext/session/mod_mm.h
+++ b/ext/session/mod_mm.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/session/mod_user.c b/ext/session/mod_user.c
index 5d69712543..5d474deab5 100644
--- a/ext/session/mod_user.c
+++ b/ext/session/mod_user.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -44,7 +44,7 @@ ps_module ps_mod_user = {
#define SESS_ZVAL_STR(vl, a) \
{ \
- ZVAL_STR(a, zend_string_copy(vl)); \
+ ZVAL_STR_COPY(a, vl); \
}
static void ps_call_handler(zval *func, int argc, zval *argv, zval *retval TSRMLS_DC)
diff --git a/ext/session/mod_user.h b/ext/session/mod_user.h
index b1f3688a25..72a119cbab 100644
--- a/ext/session/mod_user.h
+++ b/ext/session/mod_user.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/session/mod_user_class.c b/ext/session/mod_user_class.c
index 35a681babd..7e2960cc32 100644
--- a/ext/session/mod_user_class.c
+++ b/ext/session/mod_user_class.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/session/php_session.h b/ext/session/php_session.h
index 790e116528..9fb6477056 100644
--- a/ext/session/php_session.h
+++ b/ext/session/php_session.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/session/session.c b/ext/session/session.c
index de8cf23310..63bb00e06a 100644
--- a/ext/session/session.c
+++ b/ext/session/session.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -48,7 +48,7 @@
#include "ext/standard/url_scanner_ex.h"
#include "ext/standard/php_rand.h" /* for RAND_MAX */
#include "ext/standard/info.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#include "ext/standard/url.h"
#include "ext/standard/basic_functions.h"
#include "ext/standard/head.h"
@@ -1268,7 +1268,8 @@ static void php_session_remove_cookie(TSRMLS_D) {
zend_llist_element *current;
char *session_cookie;
zend_string *e_session_name;
- int session_cookie_len, len = sizeof("Set-Cookie")-1;
+ int session_cookie_len;
+ uint len = sizeof("Set-Cookie")-1;
e_session_name = php_url_encode(PS(session_name), strlen(PS(session_name)));
spprintf(&session_cookie, 0, "Set-Cookie: %s=", e_session_name->val);
diff --git a/ext/shmop/php_shmop.h b/ext/shmop/php_shmop.h
index b9eaba6f07..4ee6d4f61c 100644
--- a/ext/shmop/php_shmop.h
+++ b/ext/shmop/php_shmop.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/shmop/shmop.dsp b/ext/shmop/shmop.dsp
deleted file mode 100644
index 848f0bdc91..0000000000
--- a/ext/shmop/shmop.dsp
+++ /dev/null
@@ -1,107 +0,0 @@
-# Microsoft Developer Studio Project File - Name="shmop" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=shmop - Win32 Debug_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "shmop.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "shmop.mak" CFG="shmop - Win32 Debug_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "shmop - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "shmop - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "shmop - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "SHMOP_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\..\\" /I "..\..\main" /I "..\..\TSRM" /I "..\..\ZEND" /D "WIN32" /D ZEND_WIN32=1 /D PHP_WIN32=1 /D "NDEBUG" /D "PHP_EXPORTS" /D "HAVE_SHMOP" /D COMPILE_DL_SHMOP=1 /D ZEND_DEBUG=0 /D "ZTS" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "NDEBUG"
-# ADD RSC /l 0x407 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 php5ts.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_shmop.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-
-!ELSEIF "$(CFG)" == "shmop - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "SHMOP_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\..\\" /I "..\..\main" /I "..\..\TSRM" /I "..\..\ZEND" /D "WIN32" /D ZEND_DEBUG=1 /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "PHP_EXPORTS" /D "COMPILE_DL_SHMOP" /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_SHMOP=1 /D ZTS=1 /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "_DEBUG"
-# ADD RSC /l 0x407 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 php5ts_debug.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_shmop.dll" /pdbtype:sept /libpath:"..\..\Debug_TS"
-
-!ENDIF
-
-# Begin Target
-
-# Name "shmop - Win32 Release_TS"
-# Name "shmop - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\shmop.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_shmop.h
-# End Source File
-# End Group
-# End Target
-# End Project
diff --git a/ext/simplexml/php_simplexml.h b/ext/simplexml/php_simplexml.h
index b908e4c722..780974c0c9 100644
--- a/ext/simplexml/php_simplexml.h
+++ b/ext/simplexml/php_simplexml.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/simplexml/php_simplexml_exports.h b/ext/simplexml/php_simplexml_exports.h
index 6cdda1be4a..82e5aff9e4 100644
--- a/ext/simplexml/php_simplexml_exports.h
+++ b/ext/simplexml/php_simplexml_exports.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/simplexml/simplexml.c b/ext/simplexml/simplexml.c
index db4944ff5a..366a6f0d3b 100644
--- a/ext/simplexml/simplexml.c
+++ b/ext/simplexml/simplexml.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/simplexml/simplexml.dsp b/ext/simplexml/simplexml.dsp
deleted file mode 100644
index 79df918703..0000000000
--- a/ext/simplexml/simplexml.dsp
+++ /dev/null
@@ -1,111 +0,0 @@
-# Microsoft Developer Studio Project File - Name="simplexml" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=simplexml - Win32 Debug_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "simplexml.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "simplexml.mak" CFG="simplexml - Win32 Debug_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "simplexml - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "simplexml - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "simplexml - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "c:\php\5d\extensions"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "SIMPLEXML_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /I "..\..\..\php5" /I "..\..\..\php5\main" /I "..\..\..\php5\Zend" /I "..\..\..\php5\TSRM" /D ZEND_DEBUG=1 /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D COMPILE_DL_SIMPLEXML=1 /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "SIMPLEXML_EXPORTS" /D "LIBXML_THREAD_ENABLED" /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 php5ts_debug.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept /libpath:"..\..\..\php5\Debug_TS"
-
-!ELSEIF "$(CFG)" == "simplexml - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "SIMPLEXML_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MT /W3 /GX /O2 /I "..\..\..\php5\main" /I "..\..\..\php5\Zend" /I "..\..\..\php5\TSRM" /I "..\..\..\php5\win32" /I "..\..\..\php5" /D ZTS=1 /D ZEND_DEBUG=0 /D "ZEND_WIN32" /D "PHP_WIN32" /D COMPILE_DL_SIMPLEXML=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "SIMPLEXML_EXPORTS" /D "LIBXML_THREAD_ENABLED" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 php5ts.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /libpath:"..\..\..\php5\Release_TS" /libpath:"..\..\..\php5\Release_TS_Inline"
-
-!ENDIF
-
-# Begin Target
-
-# Name "simplexml - Win32 Debug_TS"
-# Name "simplexml - Win32 Release_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\simplexml.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_simplexml.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# End Target
-# End Project
diff --git a/ext/simplexml/sxe.c b/ext/simplexml/sxe.c
index e237d2fb95..27d1e9b0f2 100644
--- a/ext/simplexml/sxe.c
+++ b/ext/simplexml/sxe.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/simplexml/sxe.h b/ext/simplexml/sxe.h
index 629e7b31d4..a08c8f7300 100644
--- a/ext/simplexml/sxe.h
+++ b/ext/simplexml/sxe.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/skeleton/skeleton.dsp b/ext/skeleton/skeleton.dsp
deleted file mode 100644
index c3c67c7e34..0000000000
--- a/ext/skeleton/skeleton.dsp
+++ /dev/null
@@ -1,113 +0,0 @@
-# Microsoft Developer Studio Project File - Name="extname" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=extname - Win32 Release_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "extname.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "extname.mak" CFG="extname - Win32 Release_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "extname - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "extname - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "extname - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\TSRM" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "COMPILE_DL_EXTNAME" /D ZTS=1 /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /D ZEND_DEBUG=0 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "EXTNAME_EXPORTS" /D "COMPILE_DL_EXTNAME" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_EXTNAME=1 /D "LIBZEND_EXPORTS" /FR /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib /nologo /dll /machine:I386
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_extname.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-
-!ELSEIF "$(CFG)" == "extname - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "COMPILE_DL_EXTNAME" /D ZTS=1 /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "EXTNAME_EXPORTS" /D "COMPILE_DL_EXTNAME" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_EXTNAME=1 /D "LIBZEND_EXPORTS" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib /nologo /dll /machine:I386
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts_debug.lib /nologo /dll /machine:I386 /out:"..\..\Debug_TS/php_extname.dll" /libpath:"..\..\Debug_TS"
-
-!ENDIF
-
-# Begin Target
-
-# Name "extname - Win32 Release_TS"
-# Name "extname - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\extname.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_extname.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# End Target
-# End Project
diff --git a/ext/skeleton/tests/001.phpt b/ext/skeleton/tests/001.phpt
index a375577e1b..88f5795650 100644
--- a/ext/skeleton/tests/001.phpt
+++ b/ext/skeleton/tests/001.phpt
@@ -13,7 +13,7 @@ echo "extname extension is available";
to pass, differences between the output and the
expected text are interpreted as failure
- see php5/README.TESTING for further information on
+ see php7/README.TESTING for further information on
writing regression tests
*/
?>
diff --git a/ext/snmp/php_snmp.h b/ext/snmp/php_snmp.h
index 6e170ffe71..610fff11c7 100644
--- a/ext/snmp/php_snmp.h
+++ b/ext/snmp/php_snmp.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c
index f2eb434b9c..250b1f0ebe 100644
--- a/ext/snmp/snmp.c
+++ b/ext/snmp/snmp.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/snmp/snmp.dsp b/ext/snmp/snmp.dsp
deleted file mode 100644
index 3cc62338bd..0000000000
--- a/ext/snmp/snmp.dsp
+++ /dev/null
@@ -1,109 +0,0 @@
-# Microsoft Developer Studio Project File - Name="snmp" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=snmp - Win32 Release_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "snmp.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "snmp.mak" CFG="snmp - Win32 Release_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "snmp - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "snmp - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "snmp - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\TSRM" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "COMPILE_DL_SNMP" /D ZTS=1 /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /D ZEND_DEBUG=0 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "SNMP_EXPORTS" /D "COMPILE_DL_SNMP" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_SNMP=1 /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib /nologo /dll /machine:I386
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib libsnmp.lib wsock32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_snmp.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-
-!ELSEIF "$(CFG)" == "snmp - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "COMPILE_DL_SNMP" /D ZTS=1 /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "SNMP_EXPORTS" /D "COMPILE_DL_SNMP" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_SNMP=1 /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib /nologo /dll /machine:I386
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts_debug.lib libsnmp.lib wsock32.lib /nologo /dll /machine:I386 /out:"..\..\Debug_TS/php_snmp.dll" /libpath:"..\..\Debug_TS"
-
-!ENDIF
-
-# Begin Target
-
-# Name "snmp - Win32 Release_TS"
-# Name "snmp - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\snmp.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_snmp.h
-# End Source File
-# End Group
-# End Target
-# End Project
diff --git a/ext/soap/php_encoding.c b/ext/soap/php_encoding.c
index 802a0773cb..d34587b85e 100644
--- a/ext/soap/php_encoding.c
+++ b/ext/soap/php_encoding.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -813,7 +813,7 @@ static zval *to_zval_hexbin(zval *ret, encodeTypePtr type, xmlNodePtr data TSRML
}
}
str->val[str->len] = '\0';
- ZVAL_STR(ret, str);
+ ZVAL_NEW_STR(ret, str);
} else {
ZVAL_EMPTY_STRING(ret);
}
@@ -1201,7 +1201,7 @@ static zval* get_zval_property(zval* object, char* name, zval *rv TSRMLS_DC)
/* Hack for bug #32455 */
zend_property_info *property_info;
- property_info = zend_get_property_info(Z_OBJCE_P(object), &member, 1 TSRMLS_CC);
+ property_info = zend_get_property_info(Z_OBJCE_P(object), Z_STR(member), 1 TSRMLS_CC);
EG(scope) = old_scope;
if (property_info && zend_hash_exists(Z_OBJPROP_P(object), property_info->name)) {
zval_ptr_dtor(&member);
@@ -1984,7 +1984,7 @@ static xmlNodePtr to_xml_object(encodeTypePtr type, zval *data, int style, xmlNo
if (Z_TYPE_P(data) == IS_OBJECT) {
const char *class_name;
- zend_unmangle_property_name(str_key->val, str_key->len, &class_name, &prop_name);
+ zend_unmangle_property_name(str_key, &class_name, &prop_name);
} else {
prop_name = str_key->val;
}
@@ -2441,7 +2441,7 @@ iterator_done:
smart_str_appendl(&array_type,"xsd:ur-type",sizeof("xsd:ur-type")-1);
}
smart_str_appendc(&array_type, '[');
- smart_str_append(&array_type, &array_size);
+ smart_str_append_smart_str(&array_type, &array_size);
smart_str_appendc(&array_type, ']');
smart_str_0(&array_type);
set_ns_prop(xmlParam, SOAP_1_1_ENC_NAMESPACE, "arrayType", array_type.s->val);
diff --git a/ext/soap/php_encoding.h b/ext/soap/php_encoding.h
index adcccd3612..4424116524 100644
--- a/ext/soap/php_encoding.h
+++ b/ext/soap/php_encoding.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/soap/php_http.c b/ext/soap/php_http.c
index d1fd2d51ae..a1cee555a8 100644
--- a/ext/soap/php_http.c
+++ b/ext/soap/php_http.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -595,7 +595,7 @@ try_again:
smart_str_append_const(&soap_headers, "User-Agent: PHP-SOAP/"PHP_VERSION"\r\n");
}
- smart_str_append(&soap_headers, &soap_headers_z);
+ smart_str_append_smart_str(&soap_headers, &soap_headers_z);
if (soap_version == SOAP_1_2) {
smart_str_append_const(&soap_headers,"Content-Type: application/soap+xml; charset=utf-8");
diff --git a/ext/soap/php_http.h b/ext/soap/php_http.h
index 3fcc053741..b752641b1b 100644
--- a/ext/soap/php_http.h
+++ b/ext/soap/php_http.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/soap/php_packet_soap.c b/ext/soap/php_packet_soap.c
index 12fc31786f..52fa71d4e0 100644
--- a/ext/soap/php_packet_soap.c
+++ b/ext/soap/php_packet_soap.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/soap/php_packet_soap.h b/ext/soap/php_packet_soap.h
index dacf5055a2..632470f255 100644
--- a/ext/soap/php_packet_soap.h
+++ b/ext/soap/php_packet_soap.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/soap/php_schema.c b/ext/soap/php_schema.c
index 2c4c6c9189..b5aa5f21c2 100644
--- a/ext/soap/php_schema.c
+++ b/ext/soap/php_schema.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/soap/php_schema.h b/ext/soap/php_schema.h
index d68db88edc..55595f2ad8 100644
--- a/ext/soap/php_schema.h
+++ b/ext/soap/php_schema.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/soap/php_sdl.c b/ext/soap/php_sdl.c
index 587695b943..798c06fdd2 100644
--- a/ext/soap/php_sdl.c
+++ b/ext/soap/php_sdl.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -292,7 +292,7 @@ void sdl_set_uri_credentials(sdlCtx *ctx, char *uri TSRMLS_DC)
zval new_header;
rest += 2;
- ZVAL_STR(&new_header, zend_string_alloc(Z_STRLEN_P(header) - (rest - s), 0));
+ ZVAL_NEW_STR(&new_header, zend_string_alloc(Z_STRLEN_P(header) - (rest - s), 0));
memcpy(Z_STRVAL(new_header), Z_STRVAL_P(header), s - Z_STRVAL_P(header));
memcpy(Z_STRVAL(new_header) + (s - Z_STRVAL_P(header)), rest, Z_STRLEN_P(header) - (rest - Z_STRVAL_P(header)) + 1);
ZVAL_COPY(&ctx->old_header, header);
@@ -3250,8 +3250,7 @@ sdlPtr get_sdl(zval *this_ptr, char *uri, zend_long cache_wsdl TSRMLS_DC)
smart_str_appends(&proxy,Z_STRVAL(str_port));
smart_str_0(&proxy);
zval_dtor(&str_port);
- ZVAL_STR(&str_proxy, zend_string_copy(proxy.s));
- smart_str_free(&proxy);
+ ZVAL_NEW_STR(&str_proxy, proxy.s);
if (!context) {
context = php_stream_context_alloc(TSRMLS_C);
@@ -3289,9 +3288,8 @@ sdlPtr get_sdl(zval *this_ptr, char *uri, zend_long cache_wsdl TSRMLS_DC)
}
smart_str_0(&headers);
- ZVAL_STR(&str_headers, zend_string_copy(headers.s));
+ ZVAL_NEW_STR(&str_headers, headers.s);
php_stream_context_set_option(context, "http", "header", &str_headers);
- smart_str_free(&headers);
zval_ptr_dtor(&str_headers);
}
diff --git a/ext/soap/php_sdl.h b/ext/soap/php_sdl.h
index a29e2e9a1a..cf6e26b179 100644
--- a/ext/soap/php_sdl.h
+++ b/ext/soap/php_sdl.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/soap/php_soap.dsp b/ext/soap/php_soap.dsp
deleted file mode 100644
index 4157c63320..0000000000
--- a/ext/soap/php_soap.dsp
+++ /dev/null
@@ -1,156 +0,0 @@
-# Microsoft Developer Studio Project File - Name="php_soap" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=php_soap - Win32 Debug_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "php_soap.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "php_soap.mak" CFG="php_soap - Win32 Debug_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "php_soap - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "php_soap - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "php_soap - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "PHP_SOAP_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /I "..\..\..\libxml2-2.4.12\include" /I "..\..\bind" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "PHP_SOAP_EXPORTSWS" /D "PHP_SOAP_EXPORTS" /D "ZEND_WIN32" /D "PHP_WIN32" /D "ZTS" /D ZEND_DEBUG=0 /D "COMPILE_DL_SOAP" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib libxml2.lib wsock32.lib resolv.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS\php_soap.dll" /libpath:"..\..\\" /libpath:"..\..\..\libxml2-2.4.12\lib" /libpath:"..\..\Release_TS"
-
-!ELSEIF "$(CFG)" == "php_soap - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "PHP_SOAP_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /I "..\..\..\libxml2-2.4.12\include" /I "..\..\bind" /D "WS" /D "_MBCS" /D "_USRDLL" /D "PHP_SOAP_EXPORTS" /D "WIN32" /D "ZEND_WIN32" /D "PHP_WIN32" /D "ZTS" /D ZEND_DEBUG=1 /D "COMPILE_DL_SOAP" /FR"Debug_TS/" /Fp"Debug_TS/soap.pch" /YX /Fo"Debug_TS/" /Fd"Debug_TS/" /FD /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts_debug.lib libxml2.lib wsock32.lib resolv.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS\php_soap.dll" /pdbtype:sept /libpath:"..\..\\" /libpath:"..\..\..\libxml2-2.4.12\lib" /libpath:"..\..\Debug_TS"
-# SUBTRACT LINK32 /pdb:none /incremental:no
-
-!ENDIF
-
-# Begin Target
-
-# Name "php_soap - Win32 Release_TS"
-# Name "php_soap - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\php_encoding.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_http.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_packet_soap.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_schema.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_sdl.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_xml.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\soap.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_encoding.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_http.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_packet_soap.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_schema.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_sdl.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_soap.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_xml.h
-# End Source File
-# End Group
-# End Target
-# End Project
diff --git a/ext/soap/php_soap.h b/ext/soap/php_soap.h
index efa0ac0baf..6d36792981 100644
--- a/ext/soap/php_soap.h
+++ b/ext/soap/php_soap.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -29,7 +29,7 @@
#if HAVE_PHP_SESSION && !defined(COMPILE_DL_SESSION)
#include "ext/session/php_session.h"
#endif
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#include "php_ini.h"
#include "SAPI.h"
#include <libxml/parser.h>
diff --git a/ext/soap/php_xml.c b/ext/soap/php_xml.c
index f7c8fd51e5..5ad5548c40 100644
--- a/ext/soap/php_xml.c
+++ b/ext/soap/php_xml.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/soap/php_xml.h b/ext/soap/php_xml.h
index 1eddcf9503..42d9dc9c6b 100644
--- a/ext/soap/php_xml.h
+++ b/ext/soap/php_xml.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/soap/soap.c b/ext/soap/soap.c
index 554957d512..51c62f5cd6 100644
--- a/ext/soap/soap.c
+++ b/ext/soap/soap.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -78,7 +78,7 @@ static void soap_error_handler(int error_num, const char *error_filename, const
int _old_soap_version = SOAP_GLOBAL(soap_version);\
SOAP_GLOBAL(use_soap_error_handler) = 1;\
SOAP_GLOBAL(error_code) = "Server";\
- Z_OBJ(SOAP_GLOBAL(error_object)) = Z_OBJ(EG(This));
+ Z_OBJ(SOAP_GLOBAL(error_object)) = Z_OBJ(EX(This));
#define SOAP_SERVER_END_CODE() \
SOAP_GLOBAL(use_soap_error_handler) = _old_handler;\
@@ -97,7 +97,7 @@ static void soap_error_handler(int error_num, const char *error_filename, const
int _bailout = 0;\
SOAP_GLOBAL(use_soap_error_handler) = 1;\
SOAP_GLOBAL(error_code) = "Client";\
- Z_OBJ(SOAP_GLOBAL(error_object)) = Z_OBJ(EG(This));\
+ Z_OBJ(SOAP_GLOBAL(error_object)) = Z_OBJ(EX(This));\
zend_try {
#define SOAP_CLIENT_END_CODE() \
@@ -946,7 +946,7 @@ PHP_METHOD(SoapFault, __toString)
fci.function_table = &Z_OBJCE_P(getThis())->function_table;
ZVAL_STRINGL(&fci.function_name, "gettraceasstring", sizeof("gettraceasstring")-1);
fci.symbol_table = NULL;
- fci.object = Z_OBJ(EG(This));
+ fci.object = Z_OBJ(EX(This));
fci.retval = &trace;
fci.param_count = 0;
fci.params = NULL;
@@ -1429,7 +1429,7 @@ PHP_METHOD(SoapServer, addFunction)
return;
}
- ZVAL_STR(&function_copy, zend_string_copy(f->common.function_name));
+ ZVAL_STR_COPY(&function_copy, f->common.function_name);
zend_hash_update(service->soap_functions.ft, key, &function_copy);
zend_string_release(key);
@@ -1452,7 +1452,7 @@ PHP_METHOD(SoapServer, addFunction)
zend_hash_init(service->soap_functions.ft, 0, NULL, ZVAL_PTR_DTOR, 0);
}
- ZVAL_STR(&function_copy, zend_string_copy(f->common.function_name));
+ ZVAL_STR_COPY(&function_copy, f->common.function_name);
zend_hash_update(service->soap_functions.ft, key, &function_copy);
zend_string_release(key);
} else if (Z_TYPE_P(function_name) == IS_LONG) {
@@ -1713,7 +1713,7 @@ PHP_METHOD(SoapServer, handle)
if (zend_hash_str_exists(&Z_OBJCE(tmp_soap)->function_table, php_strtolower(class_name, class_name_len), class_name_len)) {
zval c_ret, constructor;
- ZVAL_STR(&constructor, zend_string_copy(service->soap_class.ce->name));
+ ZVAL_STR_COPY(&constructor, service->soap_class.ce->name);
if (call_user_function(NULL, &tmp_soap, &constructor, &c_ret, service->soap_class.argc, service->soap_class.argv TSRMLS_CC) == FAILURE) {
php_error_docref(NULL TSRMLS_CC, E_ERROR, "Error calling constructor");
}
@@ -2621,7 +2621,8 @@ static int do_request(zval *this_ptr, xmlDoc *request, char *location, char *act
return ret;
}
-static void do_soap_call(zval* this_ptr,
+static void do_soap_call(zend_execute_data *execute_data,
+ zval* this_ptr,
char* function,
size_t function_len,
int arg_count,
@@ -2936,7 +2937,7 @@ PHP_METHOD(SoapClient, __call)
if (output_headers) {
array_init(output_headers);
}
- do_soap_call(this_ptr, function, function_len, arg_count, real_args, return_value, location, soap_action, uri, soap_headers, output_headers TSRMLS_CC);
+ do_soap_call(execute_data, this_ptr, function, function_len, arg_count, real_args, return_value, location, soap_action, uri, soap_headers, output_headers TSRMLS_CC);
if (arg_count > 0) {
efree(real_args);
}
diff --git a/ext/sockets/conversions.c b/ext/sockets/conversions.c
index febfa9abd8..d808271728 100644
--- a/ext/sockets/conversions.c
+++ b/ext/sockets/conversions.c
@@ -6,7 +6,7 @@
#endif
#include <Zend/zend_llist.h>
-#include <ext/standard/php_smart_str.h>
+#include <zend_smart_str.h>
#ifndef PHP_WIN32
# include <sys/types.h>
@@ -175,7 +175,7 @@ static void do_from_to_zval_err(struct err_s *err,
err->should_free = 1;
efree(user_msg);
- smart_str_free_ex(&path, 0);
+ smart_str_free(&path);
}
ZEND_ATTRIBUTE_FORMAT(printf, 2 ,3)
static void do_from_zval_err(ser_context *ctx, const char *fmt, ...)
@@ -562,7 +562,7 @@ static void to_zval_read_sin_addr(const char *data, zval *zv, res_context *ctx)
zend_string *str = zend_string_alloc(size - 1, 0);
memset(str->val, '\0', size);
- ZVAL_STR(zv, str);
+ ZVAL_NEW_STR(zv, str);
if (inet_ntop(AF_INET, addr, Z_STRVAL_P(zv), size) == NULL) {
do_to_zval_err(ctx, "could not convert IPv4 address to string "
@@ -614,7 +614,7 @@ static void to_zval_read_sin6_addr(const char *data, zval *zv, res_context *ctx)
memset(str->val, '\0', size);
- ZVAL_STR(zv, str);
+ ZVAL_NEW_STR(zv, str);
if (inet_ntop(AF_INET6, addr, Z_STRVAL_P(zv), size) == NULL) {
do_to_zval_err(ctx, "could not convert IPv6 address to string "
@@ -1212,7 +1212,7 @@ static void to_zval_read_iov(const char *msghdr_c, zval *zv, res_context *ctx)
memcpy(buf->val, msghdr->msg_iov[i].iov_base, buf->len);
buf->val[buf->len] = '\0';
- ZVAL_STR(&elem, buf);
+ ZVAL_NEW_STR(&elem, buf);
add_next_index_zval(zv, &elem);
bytes_left -= len;
}
diff --git a/ext/sockets/multicast.c b/ext/sockets/multicast.c
index d0bddf674a..3c076b4e7c 100644
--- a/ext/sockets/multicast.c
+++ b/ext/sockets/multicast.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/sockets/multicast.h b/ext/sockets/multicast.h
index 29eb54efd8..de76dfcec7 100644
--- a/ext/sockets/multicast.h
+++ b/ext/sockets/multicast.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/sockets/php_sockets.h b/ext/sockets/php_sockets.h
index 86729650e4..b1ee5798c9 100644
--- a/ext/sockets/php_sockets.h
+++ b/ext/sockets/php_sockets.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/sockets/sendrecvmsg.c b/ext/sockets/sendrecvmsg.c
index 91867d99e3..dcaa60ac7a 100644
--- a/ext/sockets/sendrecvmsg.c
+++ b/ext/sockets/sendrecvmsg.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/sockets/sockets.c b/ext/sockets/sockets.c
index 0da81e74f5..0dab51bed6 100644
--- a/ext/sockets/sockets.c
+++ b/ext/sockets/sockets.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -1586,7 +1586,7 @@ PHP_FUNCTION(socket_recv)
/* Rebuild buffer zval */
zval_dtor(buf);
- ZVAL_STR(buf, recv_buf);
+ ZVAL_NEW_STR(buf, recv_buf);
}
if (retval == -1) {
@@ -1673,7 +1673,7 @@ PHP_FUNCTION(socket_recvfrom)
zval_dtor(arg2);
zval_dtor(arg5);
- ZVAL_STR(arg2, recv_buf);
+ ZVAL_NEW_STR(arg2, recv_buf);
ZVAL_STRING(arg5, s_un.sun_path);
break;
@@ -1703,7 +1703,7 @@ PHP_FUNCTION(socket_recvfrom)
address = inet_ntoa(sin.sin_addr);
- ZVAL_STR(arg2, recv_buf);
+ ZVAL_NEW_STR(arg2, recv_buf);
ZVAL_STRING(arg5, address ? address : "0.0.0.0");
ZVAL_LONG(arg6, ntohs(sin.sin_port));
break;
@@ -1735,7 +1735,7 @@ PHP_FUNCTION(socket_recvfrom)
memset(addr6, 0, INET6_ADDRSTRLEN);
inet_ntop(AF_INET6, &sin6.sin6_addr, addr6, INET6_ADDRSTRLEN);
- ZVAL_STR(arg2, recv_buf);
+ ZVAL_NEW_STR(arg2, recv_buf);
ZVAL_STRING(arg5, addr6[0] ? addr6 : "::");
ZVAL_LONG(arg6, ntohs(sin6.sin6_port));
break;
diff --git a/ext/sockets/sockets.dsp b/ext/sockets/sockets.dsp
deleted file mode 100644
index 961bab784d..0000000000
--- a/ext/sockets/sockets.dsp
+++ /dev/null
@@ -1,117 +0,0 @@
-# Microsoft Developer Studio Project File - Name="sockets" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=sockets - Win32 Debug_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "sockets.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "sockets.mak" CFG="sockets - Win32 Debug_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "sockets - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "sockets - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "sockets - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MD /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "SOCKETS_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\..\bindlib_w32" /D "WIN32" /D "PHP_EXPORTS" /D "COMPILE_DL_SOCKETS" /D ZTS=1 /D HAVE_SOCKETS=1 /D ZEND_DEBUG=0 /D "NDEBUG" /D "_WINDOWS" /D "ZEND_WIN32" /D "PHP_WIN32" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "NDEBUG"
-# ADD RSC /l 0x407 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 php5ts.lib wsock32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_sockets.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-# SUBTRACT LINK32 /debug
-
-!ELSEIF "$(CFG)" == "sockets - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "SOCKETS_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\..\bindlib_w32" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "PHP_EXPORTS" /D "COMPILE_DL_SOCKETS" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_SOCKETS=1 /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "_DEBUG"
-# ADD RSC /l 0x407 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 php5ts_debug.lib wsock32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_sockets.dll" /pdbtype:sept /libpath:"..\..\Debug_TS"
-
-!ENDIF
-
-# Begin Target
-
-# Name "sockets - Win32 Release_TS"
-# Name "sockets - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\php_sockets_win.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\sockets.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_sockets.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\php_sockets_win.h
-# End Source File
-# End Group
-# End Target
-# End Project
diff --git a/ext/sockets/unix_socket_constants.h b/ext/sockets/unix_socket_constants.h
index 485b2534d2..7d183b83ae 100644
--- a/ext/sockets/unix_socket_constants.h
+++ b/ext/sockets/unix_socket_constants.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/sockets/win32_socket_constants.h b/ext/sockets/win32_socket_constants.h
index 848e14fb51..2d707e9074 100644
--- a/ext/sockets/win32_socket_constants.h
+++ b/ext/sockets/win32_socket_constants.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/sockets/windows_common.h b/ext/sockets/windows_common.h
index 9cc01ae129..5536d88a4a 100644
--- a/ext/sockets/windows_common.h
+++ b/ext/sockets/windows_common.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/spl/php_spl.c b/ext/spl/php_spl.c
index ad3bb85313..44078733d6 100644
--- a/ext/spl/php_spl.c
+++ b/ext/spl/php_spl.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -346,7 +346,7 @@ PHP_FUNCTION(spl_autoload)
* The "scope" is determined by an opcode, if it is ZEND_FETCH_CLASS we know function was called indirectly by
* the Zend engine.
*/
- zend_execute_data *ex = EG(current_execute_data);
+ zend_execute_data *ex = EX(prev_execute_data);
while (ex && (!ex->func || !ZEND_USER_CODE(ex->func->type))) {
ex = ex->prev_execute_data;
diff --git a/ext/spl/php_spl.h b/ext/spl/php_spl.h
index c2b1837e8d..534a03885e 100644
--- a/ext/spl/php_spl.h
+++ b/ext/spl/php_spl.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -60,10 +60,10 @@ PHP_MINFO_FUNCTION(spl);
ZEND_BEGIN_MODULE_GLOBALS(spl)
zend_string *autoload_extensions;
HashTable *autoload_functions;
- int autoload_running;
intptr_t hash_mask_handle;
intptr_t hash_mask_handlers;
int hash_mask_init;
+ int autoload_running;
ZEND_END_MODULE_GLOBALS(spl)
#ifdef ZTS
diff --git a/ext/spl/spl_array.c b/ext/spl/spl_array.c
index 84c3714da2..211180a08d 100644
--- a/ext/spl/spl_array.c
+++ b/ext/spl/spl_array.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -26,7 +26,7 @@
#include "php_ini.h"
#include "ext/standard/info.h"
#include "ext/standard/php_var.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#include "zend_interfaces.h"
#include "zend_exceptions.h"
diff --git a/ext/spl/spl_array.h b/ext/spl/spl_array.h
index 23ca80bc8f..c27e55bbec 100644
--- a/ext/spl/spl_array.h
+++ b/ext/spl/spl_array.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/spl/spl_directory.c b/ext/spl/spl_directory.c
index 0694e8f335..73588ff1bd 100644
--- a/ext/spl/spl_directory.c
+++ b/ext/spl/spl_directory.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -821,12 +821,12 @@ SPL_METHOD(DirectoryIterator, seek)
if (intern->u.dir.index > pos) {
/* we first rewind */
- zend_call_method_with_0_params(&EG(This), Z_OBJCE(EG(This)), &intern->u.dir.func_rewind, "rewind", NULL);
+ zend_call_method_with_0_params(&EX(This), Z_OBJCE(EX(This)), &intern->u.dir.func_rewind, "rewind", NULL);
}
while (intern->u.dir.index < pos) {
int valid = 0;
- zend_call_method_with_0_params(&EG(This), Z_OBJCE(EG(This)), &intern->u.dir.func_valid, "valid", &retval);
+ zend_call_method_with_0_params(&EX(This), Z_OBJCE(EX(This)), &intern->u.dir.func_valid, "valid", &retval);
if (!Z_ISUNDEF(retval)) {
valid = zend_is_true(&retval TSRMLS_CC);
zval_ptr_dtor(&retval);
@@ -834,7 +834,7 @@ SPL_METHOD(DirectoryIterator, seek)
if (!valid) {
break;
}
- zend_call_method_with_0_params(&EG(This), Z_OBJCE(EG(This)), &intern->u.dir.func_next, "next", NULL);
+ zend_call_method_with_0_params(&EX(This), Z_OBJCE(EX(This)), &intern->u.dir.func_next, "next", NULL);
}
} /* }}} */
@@ -2170,7 +2170,8 @@ static int spl_filesystem_file_read_line_ex(zval * this_ptr, spl_filesystem_obje
if (SPL_HAS_FLAG(intern->flags, SPL_FILE_OBJECT_READ_CSV)) {
return spl_filesystem_file_read_csv(intern, intern->u.file.delimiter, intern->u.file.enclosure, intern->u.file.escape, NULL TSRMLS_CC);
} else {
- zend_call_method_with_0_params(this_ptr, Z_OBJCE_P(getThis()), &intern->u.file.func_getCurr, "getCurrentLine", &retval);
+ zend_execute_data *execute_data = EG(current_execute_data);
+ zend_call_method_with_0_params(this_ptr, Z_OBJCE(EX(This)), &intern->u.file.func_getCurr, "getCurrentLine", &retval);
}
if (!Z_ISUNDEF(retval)) {
if (intern->u.file.current_line || !Z_ISUNDEF(intern->u.file.current_zval)) {
@@ -2883,7 +2884,12 @@ SPL_METHOD(SplFileObject, fwrite)
}
if (ZEND_NUM_ARGS() > 1) {
- str_len = MAX(0, MIN(length, str_len));
+ if (length >= 0) {
+ str_len = MAX(0, MIN((size_t)length, str_len));
+ } else {
+ /* Negative length given, nothing to write */
+ str_len = 0;
+ }
}
if (!str_len) {
RETURN_LONG(0);
@@ -2911,7 +2917,7 @@ SPL_METHOD(SplFileObject, fread)
RETURN_FALSE;
}
- ZVAL_STR(return_value, zend_string_alloc(length, 0));
+ ZVAL_NEW_STR(return_value, zend_string_alloc(length, 0));
Z_STRLEN_P(return_value) = php_stream_read(intern->u.file.stream, Z_STRVAL_P(return_value), length);
/* needed because recv/read/gzread doesnt put a null at the end*/
diff --git a/ext/spl/spl_directory.h b/ext/spl/spl_directory.h
index 4993f67b1f..f1db1f69b9 100644
--- a/ext/spl/spl_directory.h
+++ b/ext/spl/spl_directory.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/spl/spl_dllist.c b/ext/spl/spl_dllist.c
index e02b9b2e83..0a6f97c563 100644
--- a/ext/spl/spl_dllist.c
+++ b/ext/spl/spl_dllist.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -29,7 +29,7 @@
#include "php_spl.h"
#include "ext/standard/info.h"
#include "ext/standard/php_var.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#include "spl_functions.h"
#include "spl_engine.h"
#include "spl_iterators.h"
@@ -101,8 +101,8 @@ struct _spl_dllist_object {
/* define an overloaded iterator structure */
struct _spl_dllist_it {
zend_user_iterator intern;
- int traverse_position;
spl_ptr_llist_element *traverse_pointer;
+ int traverse_position;
int flags;
};
diff --git a/ext/spl/spl_dllist.h b/ext/spl/spl_dllist.h
index c6f82ce57a..b8bd98ef6d 100644
--- a/ext/spl/spl_dllist.h
+++ b/ext/spl/spl_dllist.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/spl/spl_engine.c b/ext/spl/spl_engine.c
index 99a18c69f0..1e51484394 100644
--- a/ext/spl/spl_engine.c
+++ b/ext/spl/spl_engine.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/spl/spl_engine.h b/ext/spl/spl_engine.h
index fc82b4fe53..a621355ba4 100644
--- a/ext/spl/spl_engine.h
+++ b/ext/spl/spl_engine.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/spl/spl_exceptions.c b/ext/spl/spl_exceptions.c
index 221b25df47..3c6b724b5c 100644
--- a/ext/spl/spl_exceptions.c
+++ b/ext/spl/spl_exceptions.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/spl/spl_exceptions.h b/ext/spl/spl_exceptions.h
index 5e4e0f702c..e061c86118 100644
--- a/ext/spl/spl_exceptions.h
+++ b/ext/spl/spl_exceptions.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/spl/spl_fixedarray.c b/ext/spl/spl_fixedarray.c
index a025a376ab..ee5ef6b990 100644
--- a/ext/spl/spl_fixedarray.c
+++ b/ext/spl/spl_fixedarray.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/spl/spl_fixedarray.h b/ext/spl/spl_fixedarray.h
index 9011e8c1d5..a61f7ef486 100644
--- a/ext/spl/spl_fixedarray.h
+++ b/ext/spl/spl_fixedarray.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/spl/spl_functions.c b/ext/spl/spl_functions.c
index 13440355ce..f409927271 100644
--- a/ext/spl/spl_functions.c
+++ b/ext/spl/spl_functions.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -84,8 +84,7 @@ void spl_add_class_name(zval *list, zend_class_entry *pce, int allow, int ce_fla
if ((tmp = zend_hash_find(Z_ARRVAL_P(list), pce->name)) == NULL) {
zval t;
- zend_string_addref(pce->name);
- ZVAL_STR(&t, pce->name);
+ ZVAL_STR_COPY(&t, pce->name);
zend_hash_add(Z_ARRVAL_P(list), pce->name, &t);
}
}
diff --git a/ext/spl/spl_functions.h b/ext/spl/spl_functions.h
index 88ae478a02..3381975e6c 100644
--- a/ext/spl/spl_functions.h
+++ b/ext/spl/spl_functions.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/spl/spl_heap.c b/ext/spl/spl_heap.c
index 97d95d2acf..d29150c1d6 100644
--- a/ext/spl/spl_heap.c
+++ b/ext/spl/spl_heap.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/spl/spl_heap.h b/ext/spl/spl_heap.h
index a3ac4a8f5c..7d0a8a319d 100644
--- a/ext/spl/spl_heap.h
+++ b/ext/spl/spl_heap.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/spl/spl_iterators.c b/ext/spl/spl_iterators.c
index dcc2a8a573..dddc8c5e73 100644
--- a/ext/spl/spl_iterators.c
+++ b/ext/spl/spl_iterators.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -35,7 +35,7 @@
#include "spl_directory.h"
#include "spl_array.h"
#include "spl_exceptions.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#ifdef accept
#undef accept
@@ -2264,7 +2264,7 @@ SPL_METHOD(RecursiveRegexIterator, getChildren)
zend_call_method_with_0_params(&intern->inner.zobject, intern->inner.ce, NULL, "getchildren", &retval);
if (!EG(exception)) {
- ZVAL_STR(&regex, zend_string_copy(intern->u.regex.regex));
+ ZVAL_STR_COPY(&regex, intern->u.regex.regex);
spl_instantiate_arg_ex2(Z_OBJCE_P(getThis()), return_value, &retval, &regex TSRMLS_CC);
zval_ptr_dtor(&regex);
}
diff --git a/ext/spl/spl_iterators.h b/ext/spl/spl_iterators.h
index 7435ce7f27..f0740275dc 100644
--- a/ext/spl/spl_iterators.h
+++ b/ext/spl/spl_iterators.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -154,12 +154,12 @@ typedef struct _spl_dual_it_object {
} append;
#if HAVE_PCRE || HAVE_BUNDLED_PCRE
struct {
- int use_flags;
- zend_long flags;
- regex_mode mode;
- zend_long preg_flags;
+ zend_long flags;
+ zend_long preg_flags;
pcre_cache_entry *pce;
zend_string *regex;
+ regex_mode mode;
+ int use_flags;
} regex;
#endif
_spl_cbfilter_it_intern *cbfilter;
diff --git a/ext/spl/spl_observer.c b/ext/spl/spl_observer.c
index bcb316a744..d3ce72aaa3 100644
--- a/ext/spl/spl_observer.c
+++ b/ext/spl/spl_observer.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -28,7 +28,7 @@
#include "ext/standard/info.h"
#include "ext/standard/php_array.h"
#include "ext/standard/php_var.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#include "zend_interfaces.h"
#include "zend_exceptions.h"
diff --git a/ext/spl/spl_observer.h b/ext/spl/spl_observer.h
index 51573d732f..640f79cde3 100644
--- a/ext/spl/spl_observer.h
+++ b/ext/spl/spl_observer.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/sqlite3/php_sqlite3.h b/ext/sqlite3/php_sqlite3.h
index 2c19b9d9c4..5c7dfcfa5a 100644
--- a/ext/sqlite3/php_sqlite3.h
+++ b/ext/sqlite3/php_sqlite3.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/sqlite3/php_sqlite3_structs.h b/ext/sqlite3/php_sqlite3_structs.h
index 5a291a9a50..3036809856 100644
--- a/ext/sqlite3/php_sqlite3_structs.h
+++ b/ext/sqlite3/php_sqlite3_structs.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/sqlite3/sqlite3.c b/ext/sqlite3/sqlite3.c
index 4981fad416..af3dec0681 100644
--- a/ext/sqlite3/sqlite3.c
+++ b/ext/sqlite3/sqlite3.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/array.c b/ext/standard/array.c
index 09aaddfbf5..c8e79957b5 100644
--- a/ext/standard/array.c
+++ b/ext/standard/array.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -45,7 +45,7 @@
#include "basic_functions.h"
#include "php_string.h"
#include "php_rand.h"
-#include "php_smart_str.h"
+#include "zend_smart_str.h"
#ifdef HAVE_SPL
#include "ext/spl/spl_array.h"
#endif
@@ -706,12 +706,12 @@ static int php_array_user_key_compare(const void *a, const void *b TSRMLS_DC) /*
if (f->key == NULL) {
ZVAL_LONG(&args[0], f->h);
} else {
- ZVAL_STR(&args[0], zend_string_copy(f->key));
+ ZVAL_STR_COPY(&args[0], f->key);
}
if (s->key == NULL) {
ZVAL_LONG(&args[1], s->h);
} else {
- ZVAL_STR(&args[1], zend_string_copy(s->key));
+ ZVAL_STR_COPY(&args[1], s->key);
}
BG(user_compare_fci).param_count = 2;
@@ -1427,7 +1427,7 @@ PHP_FUNCTION(extract)
if (var_exists && var_name->len == sizeof("this")-1 && !strcmp(var_name->val, "this") && EG(scope) && EG(scope)->name->len != 0) {
break;
}
- ZVAL_STR(&final_name, zend_string_copy(var_name));
+ ZVAL_STR_COPY(&final_name, var_name);
break;
case EXTR_PREFIX_IF_EXISTS:
@@ -1438,7 +1438,7 @@ PHP_FUNCTION(extract)
case EXTR_PREFIX_SAME:
if (!var_exists && var_name->len != 0) {
- ZVAL_STR(&final_name, zend_string_copy(var_name));
+ ZVAL_STR_COPY(&final_name, var_name);
}
/* break omitted intentionally */
@@ -1453,14 +1453,14 @@ PHP_FUNCTION(extract)
if (!php_valid_var_name(var_name->val, var_name->len)) {
php_prefix_varname(&final_name, prefix, var_name->val, var_name->len, 1 TSRMLS_CC);
} else {
- ZVAL_STR(&final_name, zend_string_copy(var_name));
+ ZVAL_STR_COPY(&final_name, var_name);
}
}
break;
default:
if (!var_exists) {
- ZVAL_STR(&final_name, zend_string_copy(var_name));
+ ZVAL_STR_COPY(&final_name, var_name);
}
break;
}
@@ -1528,7 +1528,7 @@ static void php_compact_var(HashTable *eg_active_symbol_table, zval *return_valu
PHP_FUNCTION(compact)
{
zval *args = NULL; /* function arguments array */
- int num_args, i;
+ uint32_t num_args, i;
zend_array *symbol_table;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "+", &args, &num_args) == FAILURE) {
@@ -1826,7 +1826,7 @@ static void php_array_data_shuffle(zval *array TSRMLS_DC) /* {{{ */
for (j = 0; j < n_elems; j++) {
p = hash->arData + j;
- if (p->key && !IS_INTERNED(p->key)) {
+ if (p->key) {
zend_string_release(p->key);
}
p->h = j;
@@ -2085,7 +2085,7 @@ static void _phpi_pop(INTERNAL_FUNCTION_PARAMETERS, int off_the_end)
zend_hash_rehash(Z_ARRVAL_P(stack));
}
}
- } else if (!key && Z_ARRVAL_P(stack)->nNextFreeElement > 0 && index >= Z_ARRVAL_P(stack)->nNextFreeElement - 1) {
+ } else if (!key && Z_ARRVAL_P(stack)->nNextFreeElement > 0 && index >= (zend_ulong)(Z_ARRVAL_P(stack)->nNextFreeElement - 1)) {
Z_ARRVAL_P(stack)->nNextFreeElement = Z_ARRVAL_P(stack)->nNextFreeElement - 1;
}
@@ -2605,7 +2605,7 @@ PHP_FUNCTION(array_keys)
if (add_key) {
if (str_idx) {
- ZVAL_STR(&new_val, zend_string_copy(str_idx));
+ ZVAL_STR_COPY(&new_val, str_idx);
} else {
ZVAL_LONG(&new_val, num_idx);
}
@@ -2889,14 +2889,14 @@ PHP_FUNCTION(array_flip)
ZEND_HASH_FOREACH_KEY_VAL(Z_ARRVAL_P(array), num_idx, str_idx, entry) {
if (Z_TYPE_P(entry) == IS_LONG) {
if (str_idx) {
- ZVAL_STR(&data, zend_string_copy(str_idx));
+ ZVAL_STR_COPY(&data, str_idx);
} else {
ZVAL_LONG(&data, num_idx);
}
zend_hash_index_update(Z_ARRVAL_P(return_value), Z_LVAL_P(entry), &data);
} else if (Z_TYPE_P(entry) == IS_STRING) {
if (str_idx) {
- ZVAL_STR(&data, zend_string_copy(str_idx));
+ ZVAL_STR_COPY(&data, str_idx);
} else {
ZVAL_LONG(&data, num_idx);
}
@@ -3174,7 +3174,7 @@ static void php_array_intersect(INTERNAL_FUNCTION_PARAMETERS, int behavior, int
int arr_argc, i, c = 0;
uint idx;
Bucket **lists, *list, **ptrs, *p;
- int req_args;
+ uint32_t req_args;
char *param_spec;
zend_fcall_info fci1, fci2;
zend_fcall_info_cache fci1_cache = empty_fcall_info_cache, fci2_cache = empty_fcall_info_cache;
@@ -3598,7 +3598,7 @@ static void php_array_diff(INTERNAL_FUNCTION_PARAMETERS, int behavior, int data_
int arr_argc, i, c;
uint idx;
Bucket **lists, *list, **ptrs, *p;
- int req_args;
+ uint32_t req_args;
char *param_spec;
zend_fcall_info fci1, fci2;
zend_fcall_info_cache fci1_cache = empty_fcall_info_cache, fci2_cache = empty_fcall_info_cache;
@@ -4366,9 +4366,9 @@ PHP_FUNCTION(array_filter)
}
} else {
if (use_type == ARRAY_FILTER_USE_BOTH) {
- ZVAL_STR(&args[1], zend_string_copy(string_key));
+ ZVAL_STR_COPY(&args[1], string_key);
} else if (use_type == ARRAY_FILTER_USE_KEY) {
- ZVAL_STR(&args[0], zend_string_copy(string_key));
+ ZVAL_STR_COPY(&args[0], string_key);
}
}
}
@@ -4423,7 +4423,8 @@ PHP_FUNCTION(array_map)
zval result;
zend_fcall_info fci = empty_fcall_info;
zend_fcall_info_cache fci_cache = empty_fcall_info_cache;
- int i, k, maxlen = 0;
+ int i;
+ uint32_t k, maxlen = 0;
#ifndef FAST_ZPP
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "f!+", &fci, &fci_cache, &arrays, &n_arrays) == FAILURE) {
diff --git a/ext/standard/assert.c b/ext/standard/assert.c
index 94fee5a1ce..65472170e2 100644
--- a/ext/standard/assert.c
+++ b/ext/standard/assert.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -59,7 +59,7 @@ static PHP_INI_MH(OnChangeCallback) /* {{{ */
ZVAL_UNDEF(&ASSERTG(callback));
}
if (new_value && (Z_TYPE(ASSERTG(callback)) != IS_UNDEF || new_value->len)) {
- ZVAL_STR(&ASSERTG(callback), zend_string_copy(new_value));
+ ZVAL_STR_COPY(&ASSERTG(callback), new_value);
}
} else {
if (ASSERTG(cb)) {
diff --git a/ext/standard/base64.c b/ext/standard/base64.c
index 0a4093f185..fd1c910234 100644
--- a/ext/standard/base64.c
+++ b/ext/standard/base64.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -59,10 +59,6 @@ PHPAPI zend_string *php_base64_encode(const unsigned char *str, size_t length) /
unsigned char *p;
zend_string *result;
- if (length < 0) {
- return NULL;
- }
-
result = zend_string_alloc(((length + 2) / 3) * 4 * sizeof(char), 0);
p = (unsigned char *)result->val;
diff --git a/ext/standard/base64.h b/ext/standard/base64.h
index 43324e4911..a31a799c3a 100644
--- a/ext/standard/base64.h
+++ b/ext/standard/base64.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c
index b45db8a9b4..5bcd3d3386 100644
--- a/ext/standard/basic_functions.c
+++ b/ext/standard/basic_functions.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -4178,8 +4178,9 @@ static int parse_opts(char * opts, opt_struct ** result)
{
opt_struct * paras = NULL;
unsigned int i, count = 0;
+ unsigned int opts_len = (unsigned int)strlen(opts);
- for (i = 0; i < strlen(opts); i++) {
+ for (i = 0; i < opts_len; i++) {
if ((opts[i] >= 48 && opts[i] <= 57) ||
(opts[i] >= 65 && opts[i] <= 90) ||
(opts[i] >= 97 && opts[i] <= 122)
@@ -4785,15 +4786,15 @@ PHP_FUNCTION(forward_static_call)
return;
}
- if (!EG(current_execute_data)->prev_execute_data->func->common.scope) {
+ if (!EX(prev_execute_data)->func->common.scope) {
zend_error(E_ERROR, "Cannot call forward_static_call() when no class scope is active");
}
fci.retval = &retval;
- if (EG(current_execute_data)->called_scope &&
- instanceof_function(EG(current_execute_data)->called_scope, fci_cache.calling_scope TSRMLS_CC)) {
- fci_cache.called_scope = EG(current_execute_data)->called_scope;
+ if (EX(called_scope) &&
+ instanceof_function(EX(called_scope), fci_cache.calling_scope TSRMLS_CC)) {
+ fci_cache.called_scope = EX(called_scope);
}
if (zend_call_function(&fci, &fci_cache TSRMLS_CC) == SUCCESS && Z_TYPE(retval) != IS_UNDEF) {
@@ -4817,9 +4818,9 @@ PHP_FUNCTION(forward_static_call_array)
zend_fcall_info_args(&fci, params TSRMLS_CC);
fci.retval = &retval;
- if (EG(current_execute_data)->called_scope &&
- instanceof_function(EG(current_execute_data)->called_scope, fci_cache.calling_scope TSRMLS_CC)) {
- fci_cache.called_scope = EG(current_execute_data)->called_scope;
+ if (EX(called_scope) &&
+ instanceof_function(EX(called_scope), fci_cache.calling_scope TSRMLS_CC)) {
+ fci_cache.called_scope = EX(called_scope);
}
if (zend_call_function(&fci, &fci_cache TSRMLS_CC) == SUCCESS && Z_TYPE(retval) != IS_UNDEF) {
@@ -4861,9 +4862,11 @@ static int user_shutdown_function_call(zval *zv TSRMLS_DC) /* {{{ */
zend_string *function_name;
if (!zend_is_callable(&shutdown_function_entry->arguments[0], 0, &function_name TSRMLS_CC)) {
- php_error(E_WARNING, "(Registered shutdown functions) Unable to call %s() - function does not exist", function_name->val);
if (function_name) {
+ php_error(E_WARNING, "(Registered shutdown functions) Unable to call %s() - function does not exist", function_name->val);
zend_string_release(function_name);
+ } else {
+ php_error(E_WARNING, "(Registered shutdown functions) Unable to call - function does not exist");
}
return 0;
}
@@ -5009,7 +5012,11 @@ PHP_FUNCTION(register_shutdown_function)
/* Prevent entering of anything but valid callback (syntax check only!) */
if (!zend_is_callable(&shutdown_function_entry.arguments[0], 0, &callback_name TSRMLS_CC)) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid shutdown callback '%s' passed", callback_name->val);
+ if (callback_name) {
+ php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid shutdown callback '%s' passed", callback_name->val);
+ } else {
+ php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid shutdown callback passed");
+ }
efree(shutdown_function_entry.arguments);
RETVAL_FALSE;
} else {
@@ -5119,7 +5126,7 @@ PHP_FUNCTION(php_strip_whitespace)
char *filename;
size_t filename_len;
zend_lex_state original_lex_state;
- zend_file_handle file_handle = {0};
+ zend_file_handle file_handle = {{0}};
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p", &filename, &filename_len) == FAILURE) {
RETURN_FALSE;
@@ -5254,7 +5261,7 @@ static int php_ini_get_option(zval *zv TSRMLS_DC, int num_args, va_list args, ze
if (ini_entry->value) {
zval zv;
- ZVAL_STR(&zv, zend_string_copy(ini_entry->value));
+ ZVAL_STR_COPY(&zv, ini_entry->value);
zend_symtable_update(Z_ARRVAL_P(ini_array), ini_entry->name, &zv);
} else {
zend_symtable_update(Z_ARRVAL_P(ini_array), ini_entry->name, &EG(uninitialized_zval));
diff --git a/ext/standard/basic_functions.h b/ext/standard/basic_functions.h
index 64a6c5363c..eaac7a1609 100644
--- a/ext/standard/basic_functions.h
+++ b/ext/standard/basic_functions.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -204,11 +204,11 @@ typedef struct _php_basic_globals {
zend_class_entry *incomplete_class;
unsigned serialize_lock; /* whether to use the locally supplied var_hash instead (__sleep/__wakeup) */
struct {
- void *var_hash;
+ struct php_serialize_data *data;
unsigned level;
} serialize;
struct {
- void *var_hash;
+ struct php_unserialize_data *data;
unsigned level;
} unserialize;
diff --git a/ext/standard/browscap.c b/ext/standard/browscap.c
index c65d0c55c8..a76fb136a3 100644
--- a/ext/standard/browscap.c
+++ b/ext/standard/browscap.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -221,7 +221,7 @@ static void php_browscap_parser_cb(zval *arg1, zval *arg2, zval *arg3, int callb
static int browscap_read_file(char *filename, browser_data *browdata, int persistent TSRMLS_DC) /* {{{ */
{
- zend_file_handle fh = {0};
+ zend_file_handle fh = {{0}};
if (filename == NULL || filename[0] == '\0') {
return FAILURE;
@@ -379,15 +379,13 @@ static int browser_reg_compare(zval *browser TSRMLS_DC, int num_args, va_list ar
number of characters changed in the user agent being checked versus
the previous match found and the current match. */
if (Z_TYPE_P(found_browser_entry) == IS_ARRAY) {
- int i, prev_len = 0, curr_len = 0, ua_len;
- zval *current_match;
+ size_t i, prev_len = 0, curr_len = 0;
+ zval *current_match = zend_hash_str_find(Z_ARRVAL_P(browser), "browser_name_pattern", sizeof("browser_name_pattern")-1);
- if ((current_match = zend_hash_str_find(Z_ARRVAL_P(browser), "browser_name_pattern", sizeof("browser_name_pattern")-1)) == NULL) {
+ if (!current_match) {
return 0;
}
- ua_len = lookup_browser_length;
-
for (i = 0; i < Z_STRLEN_P(previous_match); i++) {
switch (Z_STRVAL_P(previous_match)[i]) {
case '?':
@@ -414,7 +412,7 @@ static int browser_reg_compare(zval *browser TSRMLS_DC, int num_args, va_list ar
/* Pick which browser pattern replaces the least amount of
characters when compared to the original user agent string... */
- if (ua_len - prev_len > ua_len - curr_len) {
+ if (prev_len < curr_len) {
ZVAL_COPY_VALUE(found_browser_entry, browser);
}
}
diff --git a/ext/standard/crc32.c b/ext/standard/crc32.c
index b3a0593f41..a515b492b8 100644
--- a/ext/standard/crc32.c
+++ b/ext/standard/crc32.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/crc32.h b/ext/standard/crc32.h
index be9a99e6e2..222967dd25 100644
--- a/ext/standard/crc32.h
+++ b/ext/standard/crc32.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/credits.c b/ext/standard/credits.c
index 6df81ca029..1aeff9e679 100644
--- a/ext/standard/credits.c
+++ b/ext/standard/credits.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/credits.h b/ext/standard/credits.h
index a1f57360a5..0a501526f8 100644
--- a/ext/standard/credits.h
+++ b/ext/standard/credits.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/credits_ext.h b/ext/standard/credits_ext.h
index f77bbdf157..fa1b1325e0 100644
--- a/ext/standard/credits_ext.h
+++ b/ext/standard/credits_ext.h
@@ -1,9 +1,9 @@
/*
DO NOT EDIT THIS FILE!
- it has been automaticaly created by php5/scripts/credits from
- the information found in the various php5/ext/.../CREDITS and
- php5/sapi/.../CREDITS files
+ it has been automaticaly created by php7/scripts/credits from
+ the information found in the various php7/ext/.../CREDITS and
+ php7/sapi/.../CREDITS files
if you want to change an entry you have to edit the appropriate
CREDITS file instead
diff --git a/ext/standard/credits_sapi.h b/ext/standard/credits_sapi.h
index 634a370329..8f0b8264ce 100644
--- a/ext/standard/credits_sapi.h
+++ b/ext/standard/credits_sapi.h
@@ -1,9 +1,9 @@
/*
DO NOT EDIT THIS FILE!
- it has been automaticaly created by php5/scripts/credits from
- the information found in the various php5/ext/.../CREDITS and
- php5/sapi/.../CREDITS files
+ it has been automaticaly created by php7/scripts/credits from
+ the information found in the various php7/ext/.../CREDITS and
+ php7/sapi/.../CREDITS files
if you want to change an entry you have to edit the appropriate
CREDITS file instead
diff --git a/ext/standard/crypt.c b/ext/standard/crypt.c
index 1a9acf5bd6..9599e2f056 100644
--- a/ext/standard/crypt.c
+++ b/ext/standard/crypt.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -207,11 +207,11 @@ PHPAPI zend_string *php_crypt(const char *password, const int pass_len, const ch
crypt_res = php_crypt_blowfish_rn(password, salt, output, sizeof(output));
if (!crypt_res) {
- memset(output, 0, PHP_MAX_SALT_LEN + 1);
+ ZEND_SECURE_ZERO(output, PHP_MAX_SALT_LEN + 1);
return NULL;
} else {
result = zend_string_init(output, strlen(output), 0);
- memset(output, 0, PHP_MAX_SALT_LEN + 1);
+ ZEND_SECURE_ZERO(output, PHP_MAX_SALT_LEN + 1);
return result;
}
} else {
diff --git a/ext/standard/crypt_sha256.c b/ext/standard/crypt_sha256.c
index e53f488805..5f28bd7b9f 100644
--- a/ext/standard/crypt_sha256.c
+++ b/ext/standard/crypt_sha256.c
@@ -520,7 +520,7 @@ char * php_sha256_crypt_r(const char *key, const char *salt, char *buffer, int b
if (rounds_custom) {
#ifdef PHP_WIN32
- int n = _snprintf(cp, MAX(0, buflen), "%s%u$", sha256_rounds_prefix, rounds);
+ int n = _snprintf(cp, MAX(0, buflen), "%s" ZEND_ULONG_FMT "$", sha256_rounds_prefix, rounds);
#else
int n = snprintf(cp, MAX(0, buflen), "%s%zu$", sha256_rounds_prefix, rounds);
#endif
@@ -571,18 +571,17 @@ char * php_sha256_crypt_r(const char *key, const char *salt, char *buffer, int b
inside the SHA256 implementation as well. */
sha256_init_ctx(&ctx);
sha256_finish_ctx(&ctx, alt_result);
- memset(temp_result, '\0', sizeof(temp_result));
- memset(p_bytes, '\0', key_len);
- memset(s_bytes, '\0', salt_len);
- memset(&ctx, '\0', sizeof(ctx));
- memset(&alt_ctx, '\0', sizeof(alt_ctx));
+ ZEND_SECURE_ZERO(temp_result, sizeof(temp_result));
+ ZEND_SECURE_ZERO(p_bytes, key_len);
+ ZEND_SECURE_ZERO(s_bytes, salt_len);
+ ZEND_SECURE_ZERO(&ctx, sizeof(ctx));
+ ZEND_SECURE_ZERO(&alt_ctx, sizeof(alt_ctx));
if (copied_key != NULL) {
- memset(copied_key, '\0', key_len);
-
+ ZEND_SECURE_ZERO(copied_key, key_len);
}
if (copied_salt != NULL) {
- memset(copied_salt, '\0', salt_len);
+ ZEND_SECURE_ZERO(copied_salt, salt_len);
}
return buffer;
diff --git a/ext/standard/crypt_sha512.c b/ext/standard/crypt_sha512.c
index a673bfac1c..df5f3d109e 100644
--- a/ext/standard/crypt_sha512.c
+++ b/ext/standard/crypt_sha512.c
@@ -555,7 +555,7 @@ php_sha512_crypt_r(const char *key, const char *salt, char *buffer, int buflen)
if (rounds_custom) {
#ifdef PHP_WIN32
- int n = _snprintf(cp, MAX(0, buflen), "%s%u$", sha512_rounds_prefix, rounds);
+ int n = _snprintf(cp, MAX(0, buflen), "%s" ZEND_ULONG_FMT "$", sha512_rounds_prefix, rounds);
#else
int n = snprintf(cp, MAX(0, buflen), "%s%zu$", sha512_rounds_prefix, rounds);
#endif
@@ -619,16 +619,16 @@ php_sha512_crypt_r(const char *key, const char *salt, char *buffer, int buflen)
inside the SHA512 implementation as well. */
sha512_init_ctx(&ctx);
sha512_finish_ctx(&ctx, alt_result);
- memset(temp_result, '\0', sizeof(temp_result));
- memset(p_bytes, '\0', key_len);
- memset(s_bytes, '\0', salt_len);
- memset(&ctx, '\0', sizeof(ctx));
- memset(&alt_ctx, '\0', sizeof(alt_ctx));
+ ZEND_SECURE_ZERO(temp_result, sizeof(temp_result));
+ ZEND_SECURE_ZERO(p_bytes, key_len);
+ ZEND_SECURE_ZERO(s_bytes, salt_len);
+ ZEND_SECURE_ZERO(&ctx, sizeof(ctx));
+ ZEND_SECURE_ZERO(&alt_ctx, sizeof(alt_ctx));
if (copied_key != NULL) {
- memset(copied_key, '\0', key_len);
+ ZEND_SECURE_ZERO(copied_key, key_len);
}
if (copied_salt != NULL) {
- memset(copied_salt, '\0', salt_len);
+ ZEND_SECURE_ZERO(copied_salt, salt_len);
}
return buffer;
diff --git a/ext/standard/css.c b/ext/standard/css.c
index 9ce6138015..f4469bea30 100644
--- a/ext/standard/css.c
+++ b/ext/standard/css.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/css.h b/ext/standard/css.h
index b3c79f2429..408abc1787 100644
--- a/ext/standard/css.h
+++ b/ext/standard/css.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/cyr_convert.c b/ext/standard/cyr_convert.c
index e36b8c8d69..1718b75729 100644
--- a/ext/standard/cyr_convert.c
+++ b/ext/standard/cyr_convert.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -201,11 +201,11 @@ _cyr_mac = {
* d - x-cp866
* m - x-mac-cyrillic
*****************************************************************************/
-static char * php_convert_cyr_string(unsigned char *str, int length, char from, char to TSRMLS_DC)
+static char * php_convert_cyr_string(unsigned char *str, size_t length, char from, char to TSRMLS_DC)
{
const unsigned char *from_table, *to_table;
unsigned char tmp;
- int i;
+ size_t i;
from_table = NULL;
to_table = NULL;
@@ -258,8 +258,7 @@ static char * php_convert_cyr_string(unsigned char *str, int length, char from,
if (!str)
return (char *)str;
- for( i = 0; i<length; i++)
- {
+ for (i = 0; i < length; i++) {
tmp = (from_table == NULL)? str[i] : from_table[ str[i] ];
str[i] = (to_table == NULL) ? tmp : to_table[tmp + 256];
}
@@ -281,7 +280,7 @@ PHP_FUNCTION(convert_cyr_string)
str = zend_string_init(input, input_len, 0);
- php_convert_cyr_string(str->val, str->len, fr_cs[0], to_cs[0] TSRMLS_CC);
+ php_convert_cyr_string((unsigned char *) str->val, str->len, fr_cs[0], to_cs[0] TSRMLS_CC);
RETVAL_NEW_STR(str);
}
/* }}} */
diff --git a/ext/standard/cyr_convert.h b/ext/standard/cyr_convert.h
index 6b16be2960..41cce1aaa3 100644
--- a/ext/standard/cyr_convert.h
+++ b/ext/standard/cyr_convert.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/datetime.c b/ext/standard/datetime.c
index 7b6a912244..39f8669038 100644
--- a/ext/standard/datetime.c
+++ b/ext/standard/datetime.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/datetime.h b/ext/standard/datetime.h
index bb6673497c..0edaff1b00 100644
--- a/ext/standard/datetime.h
+++ b/ext/standard/datetime.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/dir.c b/ext/standard/dir.c
index 40632a0cf5..7b4ab1cd3e 100644
--- a/ext/standard/dir.c
+++ b/ext/standard/dir.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/dl.c b/ext/standard/dl.c
index 7a2a1648d4..6ea69e5b81 100644
--- a/ext/standard/dl.c
+++ b/ext/standard/dl.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/dl.h b/ext/standard/dl.h
index eee70472b5..50ed19afc0 100644
--- a/ext/standard/dl.h
+++ b/ext/standard/dl.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/dns.c b/ext/standard/dns.c
index b43bd9160a..13a1ab75df 100644
--- a/ext/standard/dns.c
+++ b/ext/standard/dns.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -535,7 +535,7 @@ static u_char *php_parserr(u_char *cp, u_char *end, querybuf *answer, int type_t
}
if (n) {
memcpy(tp->val + l2 , cp + l1 + 1, n);
- add_next_index_stringl(&entries, cp + l1 + 1, n);
+ add_next_index_stringl(&entries, (char *) cp + l1 + 1, n);
}
l1 = l1 + n + 1;
l2 = l2 + n;
diff --git a/ext/standard/dns_win32.c b/ext/standard/dns_win32.c
index aab31891da..865ad30b3e 100644
--- a/ext/standard/dns_win32.c
+++ b/ext/standard/dns_win32.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 2008-2009 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/exec.c b/ext/standard/exec.c
index 94c5a26937..28f01b338f 100644
--- a/ext/standard/exec.c
+++ b/ext/standard/exec.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/exec.h b/ext/standard/exec.h
index 8ffe471408..79b0574e28 100644
--- a/ext/standard/exec.h
+++ b/ext/standard/exec.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/file.c b/ext/standard/file.c
index 20a956df9d..446da20fb3 100644
--- a/ext/standard/file.c
+++ b/ext/standard/file.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -35,7 +35,7 @@
#include "php_open_temporary_file.h"
#include "ext/standard/basic_functions.h"
#include "php_ini.h"
-#include "php_smart_str.h"
+#include "zend_smart_str.h"
#include <stdio.h>
#include <stdlib.h>
@@ -1210,7 +1210,7 @@ PHPAPI PHP_FUNCTION(fwrite)
num_bytes = arg2len;
} else {
if (arg3 > 0) {
- num_bytes = MAX(0, MIN((size_t)arg3, arg2len));
+ num_bytes = MIN((size_t)arg3, arg2len);
} else {
num_bytes = 0;
}
@@ -1943,7 +1943,7 @@ PHPAPI size_t php_fputcsv(php_stream *stream, zval *fields, char delimiter, char
}
smart_str_appendc(&csvline, enclosure);
} else {
- smart_str_appendl(&csvline, field_str->val, field_str->len);
+ smart_str_append(&csvline, field_str);
}
if (++i != count) {
diff --git a/ext/standard/file.h b/ext/standard/file.h
index 4551d5ec44..fdace75d3b 100644
--- a/ext/standard/file.h
+++ b/ext/standard/file.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/filestat.c b/ext/standard/filestat.c
index 992f99d24e..6a06a55d94 100644
--- a/ext/standard/filestat.c
+++ b/ext/standard/filestat.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -1235,18 +1235,18 @@ PHP_FUNCTION(realpath_cache_get)
/* bucket->key is unsigned long */
if (ZEND_LONG_MAX >= bucket->key) {
- add_assoc_long(&entry, "key", bucket->key);
+ add_assoc_long_ex(&entry, "key", sizeof("key") - 1, bucket->key);
} else {
- add_assoc_double(&entry, "key", (double)bucket->key);
+ add_assoc_double_ex(&entry, "key", sizeof("key") - 1, (double)bucket->key);
}
- add_assoc_bool(&entry, "is_dir", bucket->is_dir);
- add_assoc_stringl(&entry, "realpath", bucket->realpath, bucket->realpath_len);
- add_assoc_long(&entry, "expires", bucket->expires);
+ add_assoc_bool_ex(&entry, "is_dir", sizeof("is_dir") - 1, bucket->is_dir);
+ add_assoc_stringl_ex(&entry, "realpath", sizeof("realpath") - 1, bucket->realpath, bucket->realpath_len);
+ add_assoc_long_ex(&entry, "expires", sizeof("expires") - 1, bucket->expires);
#ifdef PHP_WIN32
- add_assoc_bool(&entry, "is_rvalid", bucket->is_rvalid);
- add_assoc_bool(&entry, "is_wvalid", bucket->is_wvalid);
- add_assoc_bool(&entry, "is_readable", bucket->is_readable);
- add_assoc_bool(&entry, "is_writable", bucket->is_writable);
+ add_assoc_bool_ex(&entry, "is_rvalid", sizeof("is_rvalid") - 1, bucket->is_rvalid);
+ add_assoc_bool_ex(&entry, "is_wvalid", sizeof("is_wvalid") - 1, bucket->is_wvalid);
+ add_assoc_bool_ex(&entry, "is_readable", sizeof("is_readable") - 1, bucket->is_readable);
+ add_assoc_bool_ex(&entry, "is_writable", sizeof("is_writable") - 1, bucket->is_writable);
#endif
zend_hash_str_update(Z_ARRVAL_P(return_value), bucket->path, bucket->path_len, &entry);
bucket = bucket->next;
diff --git a/ext/standard/filters.c b/ext/standard/filters.c
index 9ab9f652fe..f0f49950bb 100644
--- a/ext/standard/filters.c
+++ b/ext/standard/filters.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -27,7 +27,7 @@
#include "ext/standard/basic_functions.h"
#include "ext/standard/file.h"
#include "ext/standard/php_string.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
/* {{{ rot13 stream filter implementation */
static char rot13_from[] = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";
@@ -263,7 +263,7 @@ static php_stream_filter *strfilter_strip_tags_create(const char *filtername, zv
ZEND_HASH_FOREACH_VAL(Z_ARRVAL_P(filterparams), tmp) {
convert_to_string_ex(tmp);
smart_str_appendc(&tags_ss, '<');
- smart_str_appendl(&tags_ss, Z_STRVAL_P(tmp), Z_STRLEN_P(tmp));
+ smart_str_append(&tags_ss, Z_STR_P(tmp));
smart_str_appendc(&tags_ss, '>');
} ZEND_HASH_FOREACH_END();
smart_str_0(&tags_ss);
@@ -322,14 +322,14 @@ struct _php_conv {
typedef struct _php_conv_base64_encode {
php_conv _super;
- unsigned char erem[3];
+ const char *lbchars;
+ size_t lbchars_len;
size_t erem_len;
unsigned int line_ccnt;
unsigned int line_len;
- const char *lbchars;
int lbchars_dup;
- size_t lbchars_len;
int persistent;
+ unsigned char erem[3];
} php_conv_base64_encode;
static php_conv_err_t php_conv_base64_encode_convert(php_conv_base64_encode *inst, const char **in_p, size_t *in_left, char **out_p, size_t *out_left);
@@ -735,12 +735,12 @@ static php_conv_err_t php_conv_base64_decode_convert(php_conv_base64_decode *ins
typedef struct _php_conv_qprint_encode {
php_conv _super;
+ const char *lbchars;
+ size_t lbchars_len;
int opts;
unsigned int line_ccnt;
unsigned int line_len;
- const char *lbchars;
int lbchars_dup;
- size_t lbchars_len;
int persistent;
unsigned int lb_ptr;
unsigned int lb_cnt;
@@ -987,11 +987,11 @@ static php_conv_err_t php_conv_qprint_encode_ctor(php_conv_qprint_encode *inst,
typedef struct _php_conv_qprint_decode {
php_conv _super;
+ const char *lbchars;
+ size_t lbchars_len;
int scan_stat;
unsigned int next_char;
- const char *lbchars;
int lbchars_dup;
- size_t lbchars_len;
int persistent;
unsigned int lb_ptr;
unsigned int lb_cnt;
@@ -1699,7 +1699,7 @@ static int strfilter_convert_append_bucket(
}
}
- if (out_buf_size - ocnt > 0) {
+ if (out_buf_size > ocnt) {
if (NULL == (new_bucket = php_stream_bucket_new(stream, out_buf, (out_buf_size - ocnt), 1, persistent TSRMLS_CC))) {
goto out_failure;
}
@@ -1831,9 +1831,9 @@ static php_stream_filter_factory strfilter_convert_factory = {
/* {{{ consumed filter implementation */
typedef struct _php_consumed_filter_data {
- int persistent;
size_t consumed;
- off_t offset;
+ zend_off_t offset;
+ int persistent;
} php_consumed_filter_data;
static php_stream_filter_status_t consumed_filter_filter(
@@ -1926,8 +1926,8 @@ typedef enum _php_chunked_filter_state {
} php_chunked_filter_state;
typedef struct _php_chunked_filter_data {
- php_chunked_filter_state state;
size_t chunk_size;
+ php_chunked_filter_state state;
int persistent;
} php_chunked_filter_data;
diff --git a/ext/standard/flock_compat.c b/ext/standard/flock_compat.c
index 05e0175311..d5d73f4c36 100644
--- a/ext/standard/flock_compat.c
+++ b/ext/standard/flock_compat.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/flock_compat.h b/ext/standard/flock_compat.h
index ab9c445561..14405022b6 100644
--- a/ext/standard/flock_compat.h
+++ b/ext/standard/flock_compat.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/formatted_print.c b/ext/standard/formatted_print.c
index 587474346a..8f211d0236 100644
--- a/ext/standard/formatted_print.c
+++ b/ext/standard/formatted_print.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -378,7 +378,7 @@ php_formatted_print(int param_count, int use_array, int format_offset TSRMLS_DC)
int always_sign;
int format_len;
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "+", &args, &argc) == FAILURE) {
+ if (zend_parse_parameters(param_count TSRMLS_CC, "+", &args, &argc) == FAILURE) {
return NULL;
}
diff --git a/ext/standard/fsock.c b/ext/standard/fsock.c
index 4fcdff276a..090d3f8f32 100644
--- a/ext/standard/fsock.c
+++ b/ext/standard/fsock.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/fsock.h b/ext/standard/fsock.h
index 8ecb889162..7a9b67eb8c 100644
--- a/ext/standard/fsock.h
+++ b/ext/standard/fsock.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/ftok.c b/ext/standard/ftok.c
index 497b283524..536fccaa3e 100644
--- a/ext/standard/ftok.c
+++ b/ext/standard/ftok.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/ftp_fopen_wrapper.c b/ext/standard/ftp_fopen_wrapper.c
index cb96c190db..2bf4e02a41 100644
--- a/ext/standard/ftp_fopen_wrapper.c
+++ b/ext/standard/ftp_fopen_wrapper.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -636,7 +636,7 @@ static size_t php_ftp_dirstream_read(php_stream *stream, char *buf, size_t count
/* Trim off trailing whitespace characters */
tmp_len--;
- while (tmp_len >= 0 &&
+ while (tmp_len > 0 &&
(ent->d_name[tmp_len] == '\n' || ent->d_name[tmp_len] == '\r' ||
ent->d_name[tmp_len] == '\t' || ent->d_name[tmp_len] == ' ')) {
ent->d_name[tmp_len--] = '\0';
diff --git a/ext/standard/head.c b/ext/standard/head.c
index 9dae9f8759..3dd18ee0fd 100644
--- a/ext/standard/head.c
+++ b/ext/standard/head.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/head.h b/ext/standard/head.h
index 59b1518676..e32810a6f3 100644
--- a/ext/standard/head.h
+++ b/ext/standard/head.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/html.c b/ext/standard/html.c
index a7c58d5bce..dfe30d9b3e 100644
--- a/ext/standard/html.c
+++ b/ext/standard/html.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -392,9 +392,9 @@ static enum entity_charset determine_charset(char *charset_hint TSRMLS_DC)
if (zenc != NULL) {
charset_hint = (char *)zend_multibyte_get_encoding_name(zenc);
if (charset_hint != NULL && (len=strlen(charset_hint)) != 0) {
- if ((len == 4) /* sizeof (none|auto|pass) */ &&
+ if ((len == 4) /* sizeof (auto|pass) */ &&
+ /* XXX should the "wchar" be ignored as well?? */
(!memcmp("pass", charset_hint, 4) ||
- !memcmp("auto", charset_hint, 4) ||
!memcmp("auto", charset_hint, 4))) {
charset_hint = NULL;
len = 0;
diff --git a/ext/standard/html.h b/ext/standard/html.h
index 0777130e0f..c7c297c90b 100644
--- a/ext/standard/html.h
+++ b/ext/standard/html.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/html_tables.h b/ext/standard/html_tables.h
index 83c78b5d78..4680343f2c 100644
--- a/ext/standard/html_tables.h
+++ b/ext/standard/html_tables.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -1094,18 +1094,17 @@ static const uni_to_enc unimap_macroman[] = {
#define ENT_STAGE3_INDEX(k) ((k) & 0x3F)
#define ENT_CODE_POINT_FROM_STAGES(i,j,k) (((i) << 12) | ((j) << 6) | (k))
-/* Table should be organized with a leading row telling the size of
- * the table and the default entity (maybe NULL) and the rest being
- * normal rows ordered by code point so that we can do a binary search */
+/* The default entity may be NULL. Binary search is still possible while
+ is senseless as there are just two rows (see also find_entity_for_char()). */
typedef union {
struct {
- unsigned size; /* number of remaining entries in the table */
const char *default_entity;
+ unsigned size; /* number of remaining entries in the table */
unsigned short default_entity_len;
} leading_entry;
struct {
- unsigned second_cp; /* second code point */
const char *entity;
+ unsigned second_cp; /* second code point */
unsigned short entity_len;
} normal_entry;
} entity_multicodepoint_row;
@@ -1145,258 +1144,258 @@ typedef struct {
/* {{{ Start of double code point tables for HTML5 */
static const entity_multicodepoint_row multi_cp_html5_0003C[] = {
- { {01, "lt", 2} },
- { {0x020D2, "nvlt", 4} },
+ { {"lt", 01, 2} },
+ { {"nvlt", 0x020D2, 4} },
};
static const entity_multicodepoint_row multi_cp_html5_0003D[] = {
- { {01, "equals", 6} },
- { {0x020E5, "bne", 3} },
+ { {"equals", 01, 6} },
+ { {"bne", 0x020E5, 3} },
};
static const entity_multicodepoint_row multi_cp_html5_0003E[] = {
- { {01, "gt", 2} },
- { {0x020D2, "nvgt", 4} },
+ { {"gt", 01, 2} },
+ { {"nvgt", 0x020D2, 4} },
};
static const entity_multicodepoint_row multi_cp_html5_00066[] = {
- { {01, NULL , 0} },
- { {0x0006A, "fjlig", 5} },
+ { {NULL, 01, 0} },
+ { {"fjlig", 0x0006A, 5} },
};
static const entity_multicodepoint_row multi_cp_html5_0205F[] = {
- { {01, "MediumSpace", 11} },
- { {0x0200A, "ThickSpace", 10} },
+ { {"MediumSpace", 01, 11} },
+ { {"ThickSpace", 0x0200A, 10} },
};
static const entity_multicodepoint_row multi_cp_html5_0219D[] = {
- { {01, "rarrw", 5} },
- { {0x00338, "nrarrw", 6} },
+ { {"rarrw", 01, 5} },
+ { {"nrarrw", 0x00338, 6} },
};
static const entity_multicodepoint_row multi_cp_html5_02202[] = {
- { {01, "part", 4} },
- { {0x00338, "npart", 5} },
+ { {"part", 01, 4} },
+ { {"npart", 0x00338, 5} },
};
static const entity_multicodepoint_row multi_cp_html5_02220[] = {
- { {01, "angle", 5} },
- { {0x020D2, "nang", 4} },
+ { {"angle", 01, 5} },
+ { {"nang", 0x020D2, 4} },
};
static const entity_multicodepoint_row multi_cp_html5_02229[] = {
- { {01, "cap", 3} },
- { {0x0FE00, "caps", 4} },
+ { {"cap", 01, 3} },
+ { {"caps", 0x0FE00, 4} },
};
static const entity_multicodepoint_row multi_cp_html5_0222A[] = {
- { {01, "cup", 3} },
- { {0x0FE00, "cups", 4} },
+ { {"cup", 01, 3} },
+ { {"cups", 0x0FE00, 4} },
};
static const entity_multicodepoint_row multi_cp_html5_0223C[] = {
- { {01, "sim", 3} },
- { {0x020D2, "nvsim", 5} },
+ { {"sim", 01, 3} },
+ { {"nvsim", 0x020D2, 5} },
};
static const entity_multicodepoint_row multi_cp_html5_0223D[] = {
- { {01, "bsim", 4} },
- { {0x00331, "race", 4} },
+ { {"bsim", 01, 4} },
+ { {"race", 0x00331, 4} },
};
static const entity_multicodepoint_row multi_cp_html5_0223E[] = {
- { {01, "ac", 2} },
- { {0x00333, "acE", 3} },
+ { {"ac", 01, 2} },
+ { {"acE", 0x00333, 3} },
};
static const entity_multicodepoint_row multi_cp_html5_02242[] = {
- { {01, "esim", 4} },
- { {0x00338, "nesim", 5} },
+ { {"esim", 01, 4} },
+ { {"nesim", 0x00338, 5} },
};
static const entity_multicodepoint_row multi_cp_html5_0224B[] = {
- { {01, "apid", 4} },
- { {0x00338, "napid", 5} },
+ { {"apid", 01, 4} },
+ { {"napid", 0x00338, 5} },
};
static const entity_multicodepoint_row multi_cp_html5_0224D[] = {
- { {01, "CupCap", 6} },
- { {0x020D2, "nvap", 4} },
+ { {"CupCap", 01, 6} },
+ { {"nvap", 0x020D2, 4} },
};
static const entity_multicodepoint_row multi_cp_html5_0224E[] = {
- { {01, "bump", 4} },
- { {0x00338, "nbump", 5} },
+ { {"bump", 01, 4} },
+ { {"nbump", 0x00338, 5} },
};
static const entity_multicodepoint_row multi_cp_html5_0224F[] = {
- { {01, "HumpEqual", 9} },
- { {0x00338, "nbumpe", 6} },
+ { {"HumpEqual", 01, 9} },
+ { {"nbumpe", 0x00338, 6} },
};
static const entity_multicodepoint_row multi_cp_html5_02250[] = {
- { {01, "esdot", 5} },
- { {0x00338, "nedot", 5} },
+ { {"esdot", 01, 5} },
+ { {"nedot", 0x00338, 5} },
};
static const entity_multicodepoint_row multi_cp_html5_02261[] = {
- { {01, "Congruent", 9} },
- { {0x020E5, "bnequiv", 7} },
+ { {"Congruent", 01, 9} },
+ { {"bnequiv", 0x020E5, 7} },
};
static const entity_multicodepoint_row multi_cp_html5_02264[] = {
- { {01, "leq", 3} },
- { {0x020D2, "nvle", 4} },
+ { {"leq", 01, 3} },
+ { {"nvle", 0x020D2, 4} },
};
static const entity_multicodepoint_row multi_cp_html5_02265[] = {
- { {01, "ge", 2} },
- { {0x020D2, "nvge", 4} },
+ { {"ge", 01, 2} },
+ { {"nvge", 0x020D2, 4} },
};
static const entity_multicodepoint_row multi_cp_html5_02266[] = {
- { {01, "lE", 2} },
- { {0x00338, "nlE", 3} },
+ { {"lE", 01, 2} },
+ { {"nlE", 0x00338, 3} },
};
static const entity_multicodepoint_row multi_cp_html5_02267[] = {
- { {01, "geqq", 4} },
- { {0x00338, "NotGreaterFullEqual", 19} },
+ { {"geqq", 01, 4} },
+ { {"NotGreaterFullEqual", 0x00338, 19} },
};
static const entity_multicodepoint_row multi_cp_html5_02268[] = {
- { {01, "lneqq", 5} },
- { {0x0FE00, "lvertneqq", 9} },
+ { {"lneqq", 01, 5} },
+ { {"lvertneqq", 0x0FE00, 9} },
};
static const entity_multicodepoint_row multi_cp_html5_02269[] = {
- { {01, "gneqq", 5} },
- { {0x0FE00, "gvertneqq", 9} },
+ { {"gneqq", 01, 5} },
+ { {"gvertneqq", 0x0FE00, 9} },
};
static const entity_multicodepoint_row multi_cp_html5_0226A[] = {
- { {02, "ll", 2} },
- { {0x00338, "nLtv", 4} },
- { {0x020D2, "nLt", 3} },
+ { {"ll", 02, 2} },
+ { {"nLtv", 0x00338, 4} },
+ { {"nLt", 0x020D2, 3} },
};
static const entity_multicodepoint_row multi_cp_html5_0226B[] = {
- { {02, "gg", 2} },
- { {0x00338, "NotGreaterGreater", 17} },
- { {0x020D2, "nGt", 3} },
+ { {"gg", 02, 2} },
+ { {"NotGreaterGreater", 0x00338, 17} },
+ { {"nGt", 0x020D2, 3} },
};
static const entity_multicodepoint_row multi_cp_html5_0227F[] = {
- { {01, "SucceedsTilde", 13} },
- { {0x00338, "NotSucceedsTilde", 16} },
+ { {"SucceedsTilde", 01, 13} },
+ { {"NotSucceedsTilde", 0x00338, 16} },
};
static const entity_multicodepoint_row multi_cp_html5_02282[] = {
- { {01, "sub", 3} },
- { {0x020D2, "vnsub", 5} },
+ { {"sub", 01, 3} },
+ { {"vnsub", 0x020D2, 5} },
};
static const entity_multicodepoint_row multi_cp_html5_02283[] = {
- { {01, "sup", 3} },
- { {0x020D2, "nsupset", 7} },
+ { {"sup", 01, 3} },
+ { {"nsupset", 0x020D2, 7} },
};
static const entity_multicodepoint_row multi_cp_html5_0228A[] = {
- { {01, "subsetneq", 9} },
- { {0x0FE00, "vsubne", 6} },
+ { {"subsetneq", 01, 9} },
+ { {"vsubne", 0x0FE00, 6} },
};
static const entity_multicodepoint_row multi_cp_html5_0228B[] = {
- { {01, "supsetneq", 9} },
- { {0x0FE00, "vsupne", 6} },
+ { {"supsetneq", 01, 9} },
+ { {"vsupne", 0x0FE00, 6} },
};
static const entity_multicodepoint_row multi_cp_html5_0228F[] = {
- { {01, "sqsub", 5} },
- { {0x00338, "NotSquareSubset", 15} },
+ { {"sqsub", 01, 5} },
+ { {"NotSquareSubset", 0x00338, 15} },
};
static const entity_multicodepoint_row multi_cp_html5_02290[] = {
- { {01, "sqsupset", 8} },
- { {0x00338, "NotSquareSuperset", 17} },
+ { {"sqsupset", 01, 8} },
+ { {"NotSquareSuperset", 0x00338, 17} },
};
static const entity_multicodepoint_row multi_cp_html5_02293[] = {
- { {01, "sqcap", 5} },
- { {0x0FE00, "sqcaps", 6} },
+ { {"sqcap", 01, 5} },
+ { {"sqcaps", 0x0FE00, 6} },
};
static const entity_multicodepoint_row multi_cp_html5_02294[] = {
- { {01, "sqcup", 5} },
- { {0x0FE00, "sqcups", 6} },
+ { {"sqcup", 01, 5} },
+ { {"sqcups", 0x0FE00, 6} },
};
static const entity_multicodepoint_row multi_cp_html5_022B4[] = {
- { {01, "LeftTriangleEqual", 17} },
- { {0x020D2, "nvltrie", 7} },
+ { {"LeftTriangleEqual", 01, 17} },
+ { {"nvltrie", 0x020D2, 7} },
};
static const entity_multicodepoint_row multi_cp_html5_022B5[] = {
- { {01, "RightTriangleEqual", 18} },
- { {0x020D2, "nvrtrie", 7} },
+ { {"RightTriangleEqual", 01, 18} },
+ { {"nvrtrie", 0x020D2, 7} },
};
static const entity_multicodepoint_row multi_cp_html5_022D8[] = {
- { {01, "Ll", 2} },
- { {0x00338, "nLl", 3} },
+ { {"Ll", 01, 2} },
+ { {"nLl", 0x00338, 3} },
};
static const entity_multicodepoint_row multi_cp_html5_022D9[] = {
- { {01, "Gg", 2} },
- { {0x00338, "nGg", 3} },
+ { {"Gg", 01, 2} },
+ { {"nGg", 0x00338, 3} },
};
static const entity_multicodepoint_row multi_cp_html5_022DA[] = {
- { {01, "lesseqgtr", 9} },
- { {0x0FE00, "lesg", 4} },
+ { {"lesseqgtr", 01, 9} },
+ { {"lesg", 0x0FE00, 4} },
};
static const entity_multicodepoint_row multi_cp_html5_022DB[] = {
- { {01, "gtreqless", 9} },
- { {0x0FE00, "gesl", 4} },
+ { {"gtreqless", 01, 9} },
+ { {"gesl", 0x0FE00, 4} },
};
static const entity_multicodepoint_row multi_cp_html5_022F5[] = {
- { {01, "isindot", 7} },
- { {0x00338, "notindot", 8} },
+ { {"isindot", 01, 7} },
+ { {"notindot", 0x00338, 8} },
};
static const entity_multicodepoint_row multi_cp_html5_022F9[] = {
- { {01, "isinE", 5} },
- { {0x00338, "notinE", 6} },
+ { {"isinE", 01, 5} },
+ { {"notinE", 0x00338, 6} },
};
static const entity_multicodepoint_row multi_cp_html5_02933[] = {
- { {01, "rarrc", 5} },
- { {0x00338, "nrarrc", 6} },
+ { {"rarrc", 01, 5} },
+ { {"nrarrc", 0x00338, 6} },
};
static const entity_multicodepoint_row multi_cp_html5_029CF[] = {
- { {01, "LeftTriangleBar", 15} },
- { {0x00338, "NotLeftTriangleBar", 18} },
+ { {"LeftTriangleBar", 01, 15} },
+ { {"NotLeftTriangleBar", 0x00338, 18} },
};
static const entity_multicodepoint_row multi_cp_html5_029D0[] = {
- { {01, "RightTriangleBar", 16} },
- { {0x00338, "NotRightTriangleBar", 19} },
+ { {"RightTriangleBar", 01, 16} },
+ { {"NotRightTriangleBar", 0x00338, 19} },
};
static const entity_multicodepoint_row multi_cp_html5_02A6D[] = {
- { {01, "congdot", 7} },
- { {0x00338, "ncongdot", 8} },
+ { {"congdot", 01, 7} },
+ { {"ncongdot", 0x00338, 8} },
};
static const entity_multicodepoint_row multi_cp_html5_02A70[] = {
- { {01, "apE", 3} },
- { {0x00338, "napE", 4} },
+ { {"apE", 01, 3} },
+ { {"napE", 0x00338, 4} },
};
static const entity_multicodepoint_row multi_cp_html5_02A7D[] = {
- { {01, "les", 3} },
- { {0x00338, "nles", 4} },
+ { {"les", 01, 3} },
+ { {"nles", 0x00338, 4} },
};
static const entity_multicodepoint_row multi_cp_html5_02A7E[] = {
- { {01, "ges", 3} },
- { {0x00338, "nges", 4} },
+ { {"ges", 01, 3} },
+ { {"nges", 0x00338, 4} },
};
static const entity_multicodepoint_row multi_cp_html5_02AA1[] = {
- { {01, "LessLess", 8} },
- { {0x00338, "NotNestedLessLess", 17} },
+ { {"LessLess", 01, 8} },
+ { {"NotNestedLessLess", 0x00338, 17} },
};
static const entity_multicodepoint_row multi_cp_html5_02AA2[] = {
- { {01, "GreaterGreater", 14} },
- { {0x00338, "NotNestedGreaterGreater", 23} },
+ { {"GreaterGreater", 01, 14} },
+ { {"NotNestedGreaterGreater", 0x00338, 23} },
};
static const entity_multicodepoint_row multi_cp_html5_02AAC[] = {
- { {01, "smte", 4} },
- { {0x0FE00, "smtes", 5} },
+ { {"smte", 01, 4} },
+ { {"smtes", 0x0FE00, 5} },
};
static const entity_multicodepoint_row multi_cp_html5_02AAD[] = {
- { {01, "late", 4} },
- { {0x0FE00, "lates", 5} },
+ { {"late", 01, 4} },
+ { {"lates", 0x0FE00, 5} },
};
static const entity_multicodepoint_row multi_cp_html5_02AAF[] = {
- { {01, "preceq", 6} },
- { {0x00338, "NotPrecedesEqual", 16} },
+ { {"preceq", 01, 6} },
+ { {"NotPrecedesEqual", 0x00338, 16} },
};
static const entity_multicodepoint_row multi_cp_html5_02AB0[] = {
- { {01, "SucceedsEqual", 13} },
- { {0x00338, "NotSucceedsEqual", 16} },
+ { {"SucceedsEqual", 01, 13} },
+ { {"NotSucceedsEqual", 0x00338, 16} },
};
static const entity_multicodepoint_row multi_cp_html5_02AC5[] = {
- { {01, "subE", 4} },
- { {0x00338, "nsubE", 5} },
+ { {"subE", 01, 4} },
+ { {"nsubE", 0x00338, 5} },
};
static const entity_multicodepoint_row multi_cp_html5_02AC6[] = {
- { {01, "supseteqq", 9} },
- { {0x00338, "nsupseteqq", 10} },
+ { {"supseteqq", 01, 9} },
+ { {"nsupseteqq", 0x00338, 10} },
};
static const entity_multicodepoint_row multi_cp_html5_02ACB[] = {
- { {01, "subsetneqq", 10} },
- { {0x0FE00, "vsubnE", 6} },
+ { {"subsetneqq", 01, 10} },
+ { {"vsubnE", 0x0FE00, 6} },
};
static const entity_multicodepoint_row multi_cp_html5_02ACC[] = {
- { {01, "supnE", 5} },
- { {0x0FE00, "varsupsetneqq", 13} },
+ { {"supnE", 01, 5} },
+ { {"varsupsetneqq", 0x0FE00, 13} },
};
static const entity_multicodepoint_row multi_cp_html5_02AFD[] = {
- { {01, "parsl", 5} },
- { {0x020E5, "nparsl", 6} },
+ { {"parsl", 01, 5} },
+ { {"nparsl", 0x020E5, 6} },
};
/* End of double code point tables }}} */
diff --git a/ext/standard/html_tables/html_table_gen.php b/ext/standard/html_tables/html_table_gen.php
index 2aae24475a..45ae5f832b 100644
--- a/ext/standard/html_tables/html_table_gen.php
+++ b/ext/standard/html_tables/html_table_gen.php
@@ -1,7 +1,7 @@
<?php
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2010 The PHP Group |
+----------------------------------------------------------------------+
@@ -23,7 +23,7 @@
$t = <<<CODE
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-%s The PHP Group |
+----------------------------------------------------------------------+
@@ -371,18 +371,17 @@ $t = <<<'CODE'
#define ENT_STAGE3_INDEX(k) ((k) & 0x3F)
#define ENT_CODE_POINT_FROM_STAGES(i,j,k) (((i) << 12) | ((j) << 6) | (k))
-/* Table should be organized with a leading row telling the size of
- * the table and the default entity (maybe NULL) and the rest being
- * normal rows ordered by code point so that we can do a binary search */
+/* The default entity may be NULL. Binary search is still possible while
+ is senseless as there are just two rows (see also find_entity_for_char()). */
typedef union {
struct {
- unsigned size; /* number of remaining entries in the table */
const char *default_entity;
+ unsigned size; /* number of remaining entries in the table */
unsigned short default_entity_len;
} leading_entry;
struct {
- unsigned second_cp; /* second code point */
const char *entity;
+ unsigned second_cp; /* second code point */
unsigned short entity_len;
} normal_entry;
} entity_multicodepoint_row;
@@ -475,16 +474,16 @@ foreach ($multicp_rows as $k => $v) {
if (key_exists("default", $v)) {
if ($v['default'] == 'GT') /* hack to make > translate to &gt; not GT; */
$v['default'] = "gt";
- echo "\t{ {", sprintf("%02d", count($v) - 1),
- ",\t\t", sprintf("\"%-21s", $v["default"].'",'), "\t",
+ echo "\t{ {", sprintf("\"%-21s", $v["default"].'",'),
+ "\t", sprintf("%02d", (count($v) - 1)), ",\t\t",
sprintf("% 2d", strlen($v["default"])), '} },', "\n";
} else {
- echo "\t{ {", sprintf("%02d", count($v)),
- ",\t\t", sprintf("%-22s", 'NULL'), ",\t0} },\n";
+ echo "\t{ {", sprintf("%-22s", 'NULL,'),
+ "\t", sprintf("%02d", count($v)), ",\t\t0} },\n";
}
unset($v["default"]);
foreach ($v as $l => $w) {
- echo "\t{ {", sprintf("0x%05s", $l), ",\t", sprintf("\"%-21s", $w.'",'), "\t",
+ echo "\t{ {", sprintf("\"%-21s", $w.'",'), "\t", sprintf("0x%05s", $l), ",\t",
sprintf("% 2d", strlen($w)), '} },', "\n";
}
echo "};\n";
diff --git a/ext/standard/http.c b/ext/standard/http.c
index 62b05ed7b5..9174163b7d 100644
--- a/ext/standard/http.c
+++ b/ext/standard/http.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -66,7 +66,7 @@ PHPAPI int php_url_encode_hash_ex(HashTable *ht, smart_str *formstr,
/* private or protected property access outside of the class */
continue;
}
- zend_unmangle_property_name_ex(key->val, key->len, &tmp, &prop_name, (int *)&prop_len);
+ zend_unmangle_property_name_ex(key, &tmp, &prop_name, &prop_len);
} else {
prop_name = key->val;
prop_len = key->len;
@@ -159,18 +159,14 @@ PHPAPI int php_url_encode_hash_ex(HashTable *ht, smart_str *formstr,
} else {
ekey = php_url_encode(prop_name, prop_len);
}
- smart_str_appendl(formstr, ekey->val, ekey->len);
+ smart_str_append(formstr, ekey);
zend_string_free(ekey);
} else {
- char *ekey;
- int ekey_len;
/* Numeric key */
if (num_prefix) {
smart_str_appendl(formstr, num_prefix, num_prefix_len);
}
- ekey_len = spprintf(&ekey, 0, "%pd", idx);
- smart_str_appendl(formstr, ekey, ekey_len);
- efree(ekey);
+ smart_str_append_long(formstr, idx);
}
smart_str_appendl(formstr, key_suffix, key_suffix_len);
smart_str_appendl(formstr, "=", 1);
@@ -182,18 +178,12 @@ PHPAPI int php_url_encode_hash_ex(HashTable *ht, smart_str *formstr,
} else {
ekey = php_url_encode(Z_STRVAL_P(zdata), Z_STRLEN_P(zdata));
}
- smart_str_appendl(formstr, ekey->val, ekey->len);
+ smart_str_append(formstr, ekey);
zend_string_free(ekey);
}
break;
case IS_LONG:
- {
- char *ekey;
- int ekey_len;
- ekey_len = spprintf(&ekey, 0, "%pd", Z_LVAL_P(zdata));
- smart_str_appendl(formstr, ekey, ekey_len);
- efree(ekey);
- }
+ smart_str_append_long(formstr, Z_LVAL_P(zdata));
break;
case IS_FALSE:
smart_str_appendl(formstr, "0", sizeof("0")-1);
@@ -221,7 +211,7 @@ PHPAPI int php_url_encode_hash_ex(HashTable *ht, smart_str *formstr,
} else {
ekey = php_url_encode(Z_STRVAL(copyzval), Z_STRLEN(copyzval));
}
- smart_str_appendl(formstr, ekey->val, ekey->len);
+ smart_str_append(formstr, ekey);
zval_ptr_dtor(&copyzval);
zend_string_free(ekey);
}
diff --git a/ext/standard/http_fopen_wrapper.c b/ext/standard/http_fopen_wrapper.c
index 4bf86a4947..27c6cf6248 100644
--- a/ext/standard/http_fopen_wrapper.c
+++ b/ext/standard/http_fopen_wrapper.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -27,7 +27,7 @@
#include "php_network.h"
#include "php_ini.h"
#include "ext/standard/basic_functions.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#include <stdio.h>
#include <stdlib.h>
@@ -422,7 +422,7 @@ finish:
ZEND_HASH_FOREACH_VAL(Z_ARRVAL_P(tmpzval), tmpheader) {
if (Z_TYPE_P(tmpheader) == IS_STRING) {
- smart_str_appendl(&tmpstr, Z_STRVAL_P(tmpheader), Z_STRLEN_P(tmpheader));
+ smart_str_append(&tmpstr, Z_STR_P(tmpheader));
smart_str_appendl(&tmpstr, "\r\n", sizeof("\r\n") - 1);
}
} ZEND_HASH_FOREACH_END();
@@ -437,7 +437,7 @@ finish:
/* Remove newlines and spaces from start and end php_trim will estrndup() */
tmp = php_trim(Z_STRVAL_P(tmpzval), Z_STRLEN_P(tmpzval), NULL, 0, NULL, 3 TSRMLS_CC);
}
- if (tmp && strlen(tmp) > 0) {
+ if (tmp && tmp[0] != '\0') {
char *s;
user_headers = estrdup(tmp);
diff --git a/ext/standard/image.c b/ext/standard/image.c
index b2b5dcd369..54159e3785 100644
--- a/ext/standard/image.c
+++ b/ext/standard/image.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -366,8 +366,8 @@ static unsigned short php_read2(php_stream * stream TSRMLS_DC)
{
unsigned char a[2];
- /* just return 0 if we hit the end-of-file */
- if((php_stream_read(stream, (char*)a, sizeof(a))) <= 0) return 0;
+ /* return 0 if we couldn't read enough data */
+ if((php_stream_read(stream, a, sizeof(a))) < sizeof(a)) return 0;
return (((unsigned short)a[0]) << 8) + ((unsigned short)a[1]);
}
@@ -647,7 +647,7 @@ static struct gfxinfo *php_handle_jpc(php_stream * stream TSRMLS_DC)
#endif
result->channels = php_read2(stream TSRMLS_CC); /* Csiz */
- if (result->channels < 0 || result->channels > 256) {
+ if (result->channels == 0 && php_stream_eof(stream) || result->channels > 256) {
efree(result);
return NULL;
}
diff --git a/ext/standard/incomplete_class.c b/ext/standard/incomplete_class.c
index 4a6a39d4ed..011407da29 100644
--- a/ext/standard/incomplete_class.c
+++ b/ext/standard/incomplete_class.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/info.c b/ext/standard/info.c
index a1a44cbae6..bc0ddddcc0 100644
--- a/ext/standard/info.c
+++ b/ext/standard/info.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -219,7 +219,7 @@ static void php_print_gpcse_array(char *name, uint name_length TSRMLS_DC)
php_info_print(string_key->val);
}
} else {
- php_info_printf("%pd", num_key);
+ php_info_printf(ZEND_ULONG_FMT, num_key);
}
php_info_print("\"]");
if (!sapi_module.phpinfo_as_text) {
@@ -585,6 +585,8 @@ PHPAPI zend_string *php_get_uname(char mode)
char *winver = php_get_windows_name();
char wincpu[20];
+ ZEND_ASSERT(winver != NULL);
+
php_get_windows_cpu(wincpu, sizeof(wincpu));
dwBuild = (DWORD)(HIWORD(dwVersion));
diff --git a/ext/standard/info.h b/ext/standard/info.h
index 8be58160ed..a28ac564ab 100644
--- a/ext/standard/info.h
+++ b/ext/standard/info.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/iptc.c b/ext/standard/iptc.c
index e815c6bfb1..75bbdd22ce 100644
--- a/ext/standard/iptc.c
+++ b/ext/standard/iptc.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -300,8 +300,8 @@ PHP_FUNCTION(iptcparse)
{
int inx = 0, len;
unsigned int tagsfound = 0;
- unsigned char *buffer, recnum, dataset, key[ 16 ];
- char *str;
+ unsigned char *buffer, recnum, dataset;
+ char *str, key[16];
size_t str_len;
zval values, *element;
diff --git a/ext/standard/lcg.c b/ext/standard/lcg.c
index 051dfc61c8..8bfa05555b 100644
--- a/ext/standard/lcg.c
+++ b/ext/standard/lcg.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/levenshtein.c b/ext/standard/levenshtein.c
index 14d75bf571..df822f45d4 100644
--- a/ext/standard/levenshtein.c
+++ b/ext/standard/levenshtein.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/link.c b/ext/standard/link.c
index fcd6b8eed9..4618ffe983 100644
--- a/ext/standard/link.c
+++ b/ext/standard/link.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/link_win32.c b/ext/standard/link_win32.c
index a1b745af8d..ab904d9571 100644
--- a/ext/standard/link_win32.c
+++ b/ext/standard/link_win32.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/mail.c b/ext/standard/mail.c
index 3404ebe2ac..96363f4cb9 100644
--- a/ext/standard/mail.c
+++ b/ext/standard/mail.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/math.c b/ext/standard/math.c
index c957ca4698..7014e6c938 100644
--- a/ext/standard/math.c
+++ b/ext/standard/math.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -220,7 +220,7 @@ static double php_asinh(double z)
return(asinh(z));
#else
# ifdef _WIN64
- if (z > 0) {
+ if (z >= 0) {
return log(z + sqrt(z * z + 1));
}
else {
diff --git a/ext/standard/md5.c b/ext/standard/md5.c
index 4938babf7a..e5359c2bcf 100644
--- a/ext/standard/md5.c
+++ b/ext/standard/md5.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -61,7 +61,7 @@ PHP_NAMED_FUNCTION(php_if_md5)
PHP_MD5Update(&context, arg->val, arg->len);
PHP_MD5Final(digest, &context);
if (raw_output) {
- RETURN_STRINGL(digest, 16);
+ RETURN_STRINGL((char *) digest, 16);
} else {
make_digest_ex(md5str, digest, 16);
RETVAL_STRING(md5str);
@@ -99,16 +99,20 @@ PHP_NAMED_FUNCTION(php_if_md5_file)
PHP_MD5Update(&context, buf, n);
}
- PHP_MD5Final(digest, &context);
-
- php_stream_close(stream);
+ /* XXX this probably can be improved with some number of retries */
+ if (!php_stream_eof(stream)) {
+ php_stream_close(stream);
+ PHP_MD5Final(digest, &context);
- if (n<0) {
RETURN_FALSE;
}
+ php_stream_close(stream);
+
+ PHP_MD5Final(digest, &context);
+
if (raw_output) {
- RETURN_STRINGL(digest, 16);
+ RETURN_STRINGL((char *) digest, 16);
} else {
make_digest_ex(md5str, digest, 16);
RETVAL_STRING(md5str);
@@ -384,5 +388,5 @@ PHPAPI void PHP_MD5Final(unsigned char *result, PHP_MD5_CTX *ctx)
result[14] = ctx->d >> 16;
result[15] = ctx->d >> 24;
- memset(ctx, 0, sizeof(*ctx));
+ ZEND_SECURE_ZERO(ctx, sizeof(*ctx));
}
diff --git a/ext/standard/md5.h b/ext/standard/md5.h
index 43f425e402..d62ade6b26 100644
--- a/ext/standard/md5.h
+++ b/ext/standard/md5.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/metaphone.c b/ext/standard/metaphone.c
index f2feb72ebf..5327869a50 100644
--- a/ext/standard/metaphone.c
+++ b/ext/standard/metaphone.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/microtime.c b/ext/standard/microtime.c
index e20223b011..811731ee20 100644
--- a/ext/standard/microtime.c
+++ b/ext/standard/microtime.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/microtime.h b/ext/standard/microtime.h
index 2af8a677c5..0a8b0dc666 100644
--- a/ext/standard/microtime.h
+++ b/ext/standard/microtime.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/pack.c b/ext/standard/pack.c
index d0792c1c17..f2bcb09723 100644
--- a/ext/standard/pack.c
+++ b/ext/standard/pack.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/pack.h b/ext/standard/pack.h
index 601cc202c2..dc4c7d6173 100644
--- a/ext/standard/pack.h
+++ b/ext/standard/pack.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/pageinfo.c b/ext/standard/pageinfo.c
index 61a4ae6ec2..8db9995d27 100644
--- a/ext/standard/pageinfo.c
+++ b/ext/standard/pageinfo.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/pageinfo.h b/ext/standard/pageinfo.h
index 204fb85c19..ec5823246a 100644
--- a/ext/standard/pageinfo.h
+++ b/ext/standard/pageinfo.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/password.c b/ext/standard/password.c
index cda10cbac0..0f75272d0e 100644
--- a/ext/standard/password.c
+++ b/ext/standard/password.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -86,7 +86,7 @@ static int php_password_salt_to64(const char *str, const size_t str_len, const s
if ((int) str_len < 0) {
return FAILURE;
}
- buffer = php_base64_encode((unsigned char*) str, (int) str_len);
+ buffer = php_base64_encode((unsigned char*) str, str_len);
if (buffer->len < out_len) {
/* Too short of an encoded string generated */
zend_string_release(buffer);
@@ -163,7 +163,7 @@ static int php_password_make_salt(size_t length, char *ret TSRMLS_DC) /* {{{ */
efree(result);
return FAILURE;
}
- memcpy(ret, result, (int) length);
+ memcpy(ret, result, length);
efree(result);
efree(buffer);
ret[length] = 0;
@@ -182,11 +182,6 @@ PHP_FUNCTION(password_get_info)
return;
}
- if (hash_len < 0) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Supplied password hash too long to safely identify");
- RETURN_FALSE;
- }
-
array_init(&options);
algo = php_password_determine_algo(hash, (size_t) hash_len);
@@ -225,11 +220,6 @@ PHP_FUNCTION(password_needs_rehash)
return;
}
- if (hash_len < 0) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Supplied password hash too long to safely identify");
- RETURN_FALSE;
- }
-
algo = php_password_determine_algo(hash, (size_t) hash_len);
if (algo != new_algo) {
@@ -409,7 +399,7 @@ PHP_FUNCTION(password_hash)
salt_len = required_salt_len;
} else {
salt = safe_emalloc(required_salt_len, 1, 1);
- memcpy(salt, buffer, (int) required_salt_len);
+ memcpy(salt, buffer, required_salt_len);
salt_len = required_salt_len;
}
efree(buffer);
diff --git a/ext/standard/php_array.h b/ext/standard/php_array.h
index c001ee5509..d86121b277 100644
--- a/ext/standard/php_array.h
+++ b/ext/standard/php_array.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_assert.h b/ext/standard/php_assert.h
index 04c85427c3..d8029b2f4f 100644
--- a/ext/standard/php_assert.h
+++ b/ext/standard/php_assert.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_browscap.h b/ext/standard/php_browscap.h
index dbe1891af3..467809dbf5 100644
--- a/ext/standard/php_browscap.h
+++ b/ext/standard/php_browscap.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_crypt.h b/ext/standard/php_crypt.h
index a23811c320..c861187649 100644
--- a/ext/standard/php_crypt.h
+++ b/ext/standard/php_crypt.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_crypt_r.c b/ext/standard/php_crypt_r.c
index 3098f247ef..dc4e27b112 100644
--- a/ext/standard/php_crypt_r.c
+++ b/ext/standard/php_crypt_r.c
@@ -1,7 +1,7 @@
/* $Id$ */
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -206,7 +206,7 @@ char * php_md5_crypt_r(const char *pw, const char *salt, char *out) {
}
/* Don't leave anything around in vm they could use. */
- memset(final, 0, sizeof(final));
+ ZEND_SECURE_ZERO(final, sizeof(final));
/* Then something really weird... */
for (i = pwl; i != 0; i >>= 1) {
@@ -288,7 +288,7 @@ char * php_md5_crypt_r(const char *pw, const char *salt, char *out) {
*p = '\0';
- memset(final, 0, sizeof(final));
+ ZEND_SECURE_ZERO(final, sizeof(final));
_destroyCtx1:
diff --git a/ext/standard/php_crypt_r.h b/ext/standard/php_crypt_r.h
index 8b78d95d3d..da5744c9df 100644
--- a/ext/standard/php_crypt_r.h
+++ b/ext/standard/php_crypt_r.h
@@ -1,7 +1,7 @@
/* $Id$ */
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_dir.h b/ext/standard/php_dir.h
index 2b9313aac4..c7999277da 100644
--- a/ext/standard/php_dir.h
+++ b/ext/standard/php_dir.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_dns.h b/ext/standard/php_dns.h
index 5823f5f20f..f37bce539a 100644
--- a/ext/standard/php_dns.h
+++ b/ext/standard/php_dns.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_ext_syslog.h b/ext/standard/php_ext_syslog.h
index e3fc582cd2..6e915bdf1d 100644
--- a/ext/standard/php_ext_syslog.h
+++ b/ext/standard/php_ext_syslog.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_filestat.h b/ext/standard/php_filestat.h
index 4f29553aea..e32c4a2cb9 100644
--- a/ext/standard/php_filestat.h
+++ b/ext/standard/php_filestat.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_fopen_wrapper.c b/ext/standard/php_fopen_wrapper.c
index 3859e5b9a4..575e8fff98 100644
--- a/ext/standard/php_fopen_wrapper.c
+++ b/ext/standard/php_fopen_wrapper.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_fopen_wrappers.h b/ext/standard/php_fopen_wrappers.h
index 341c7ad829..084efc291c 100644
--- a/ext/standard/php_fopen_wrappers.h
+++ b/ext/standard/php_fopen_wrappers.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_ftok.h b/ext/standard/php_ftok.h
index 7e702c942f..54666031fe 100644
--- a/ext/standard/php_ftok.h
+++ b/ext/standard/php_ftok.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_http.h b/ext/standard/php_http.h
index 54321b39a2..0979348314 100644
--- a/ext/standard/php_http.h
+++ b/ext/standard/php_http.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -22,7 +22,7 @@
#define PHP_HTTP_H
#include "php.h"
-#include "php_smart_str.h"
+#include "zend_smart_str.h"
PHPAPI int php_url_encode_hash_ex(HashTable *ht, smart_str *formstr,
const char *num_prefix, int num_prefix_len,
diff --git a/ext/standard/php_image.h b/ext/standard/php_image.h
index c8bb4ccc7a..3853b0e6c3 100644
--- a/ext/standard/php_image.h
+++ b/ext/standard/php_image.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_incomplete_class.h b/ext/standard/php_incomplete_class.h
index efca24acce..6001e35bbe 100644
--- a/ext/standard/php_incomplete_class.h
+++ b/ext/standard/php_incomplete_class.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_iptc.h b/ext/standard/php_iptc.h
index a076aea343..af0269ce78 100644
--- a/ext/standard/php_iptc.h
+++ b/ext/standard/php_iptc.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_lcg.h b/ext/standard/php_lcg.h
index 82141e6af2..dcc82e9511 100644
--- a/ext/standard/php_lcg.h
+++ b/ext/standard/php_lcg.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_link.h b/ext/standard/php_link.h
index 1ca4acee25..2633a33ae4 100644
--- a/ext/standard/php_link.h
+++ b/ext/standard/php_link.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_mail.h b/ext/standard/php_mail.h
index 925f58ebd5..f7ee5e983a 100644
--- a/ext/standard/php_mail.h
+++ b/ext/standard/php_mail.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_math.h b/ext/standard/php_math.h
index afdf54166f..7fb6909e7f 100644
--- a/ext/standard/php_math.h
+++ b/ext/standard/php_math.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_metaphone.h b/ext/standard/php_metaphone.h
index 14da9d8191..100b1a8bc2 100644
--- a/ext/standard/php_metaphone.h
+++ b/ext/standard/php_metaphone.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_password.h b/ext/standard/php_password.h
index a38af97626..66adc07934 100644
--- a/ext/standard/php_password.h
+++ b/ext/standard/php_password.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_rand.h b/ext/standard/php_rand.h
index 6ec0f38706..bbdf16d385 100644
--- a/ext/standard/php_rand.h
+++ b/ext/standard/php_rand.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_smart_str.h b/ext/standard/php_smart_str.h
deleted file mode 100644
index 8b79e3edbc..0000000000
--- a/ext/standard/php_smart_str.h
+++ /dev/null
@@ -1,175 +0,0 @@
-/*
- +----------------------------------------------------------------------+
- | PHP Version 5 |
- +----------------------------------------------------------------------+
- | Copyright (c) 1997-2014 The PHP Group |
- +----------------------------------------------------------------------+
- | This source file is subject to version 3.01 of the PHP license, |
- | that is bundled with this package in the file LICENSE, and is |
- | available through the world-wide-web at the following url: |
- | http://www.php.net/license/3_01.txt |
- | If you did not receive a copy of the PHP license and are unable to |
- | obtain it through the world-wide-web, please send a note to |
- | license@php.net so we can mail you a copy immediately. |
- +----------------------------------------------------------------------+
- | Author: Sascha Schumann <sascha@schumann.cx> |
- +----------------------------------------------------------------------+
- */
-
-/* $Id$ */
-
-#ifndef PHP_SMART_STR_H
-#define PHP_SMART_STR_H
-
-#include "php_smart_str_public.h"
-
-#include <stdlib.h>
-#ifndef SMART_STR_USE_REALLOC
-#include <zend.h>
-#endif
-
-#define smart_str_0(x) do { \
- if ((x)->s) { \
- (x)->s->val[(x)->s->len] = '\0'; \
- } \
-} while (0)
-
-#ifndef SMART_STR_PREALLOC
-#define SMART_STR_PREALLOC 128
-#endif
-
-#ifndef SMART_STR_START_SIZE
-#define SMART_STR_START_SIZE 78
-#endif
-
-
-#ifdef SMART_STR_USE_REALLOC
-#define SMART_STR_DO_REALLOC(b, w) do { \
- int oldlen = (b)->s->len; \
- (b)->s = erealloc((buf)->s, _STR_HEADER_SIZE + (b)->a + 1); \
- (b)->s->len = oldlen; \
-} while (0)
-#else
-#define SMART_STR_DO_REALLOC(b, w) do { \
- (b)->s = perealloc((b)->s, _STR_HEADER_SIZE + (b)->a + 1, (w)); \
-} while (0)
-#endif
-
-
-#define smart_str_alloc4(d, n, what, newlen) do { \
- if (!(d)->s) { \
- newlen = (n); \
- (d)->a = newlen < SMART_STR_START_SIZE \
- ? SMART_STR_START_SIZE \
- : newlen + SMART_STR_PREALLOC; \
- (d)->s = zend_string_alloc((d)->a, (what)); \
- (d)->s->len = 0; \
- } else { \
- newlen = (d)->s->len + (n); \
- if (newlen >= (d)->a) { \
- (d)->a = newlen + SMART_STR_PREALLOC; \
- SMART_STR_DO_REALLOC((d), (what)); \
- } \
- } \
-} while (0)
-
-#define smart_str_alloc(d, n, what) \
- smart_str_alloc4((d), (n), (what), newlen)
-
-/* wrapper */
-
-#define smart_str_appends_ex(dest, src, what) \
- smart_str_appendl_ex((dest), (src), strlen(src), (what))
-#define smart_str_appends(dest, src) \
- smart_str_appendl((dest), (src), strlen(src))
-
-#define smart_str_appendc(dest, c) \
- smart_str_appendc_ex((dest), (c), 0)
-#define smart_str_free(s) \
- smart_str_free_ex((s), 0)
-#define smart_str_appendl(dest, src, len) \
- smart_str_appendl_ex((dest), (src), (len), 0)
-#define smart_str_append(dest, src) \
- smart_str_append_ex((dest), (src), 0)
-#define smart_str_append_long(dest, val) \
- smart_str_append_long_ex((dest), (val), 0)
-#define smart_str_append_off_t(dest, val) \
- smart_str_append_off_t_ex((dest), (val), 0)
-#define smart_str_append_unsigned(dest, val) \
- smart_str_append_unsigned_ex((dest), (val), 0)
-
-#define smart_str_appendc_ex(dest, ch, what) do { \
- register size_t __nl; \
- smart_str_alloc4((dest), 1, (what), __nl); \
- (dest)->s->len = __nl; \
- ((unsigned char *) (dest)->s->val)[(dest)->s->len - 1] = (ch); \
-} while (0)
-
-#define smart_str_free_ex(buf, what) do { \
- smart_str *__s = (smart_str *) (buf); \
- if (__s->s) { \
- zend_string_release(__s->s); \
- __s->s = NULL; \
- } \
- __s->a = 0; \
-} while (0)
-
-#define smart_str_appendl_ex(dest, src, nlen, what) do { \
- register size_t __nl; \
- smart_str *__dest = (smart_str *) (dest); \
- \
- smart_str_alloc4(__dest, (nlen), (what), __nl); \
- memcpy(__dest->s->val + __dest->s->len, (src), (nlen)); \
- __dest->s->len = __nl; \
-} while (0)
-
-/*
- * these could be replaced using a braced-group inside an expression
- * for GCC compatible compilers, e.g.
- *
- * #define f(..) ({char *r;..;__r;})
- */
-
-static inline char *smart_str_print_long(char *buf, zend_long num) {
- char *r;
- _zend_print_signed_to_buf(buf, num, zend_long, r);
- return r;
-}
-
-static inline char *smart_str_print_unsigned(char *buf, zend_long num) {
- char *r;
- _zend_print_unsigned_to_buf(buf, num, zend_ulong, r);
- return r;
-}
-
-#define smart_str_append_generic_ex(dest, num, type, vartype, func) do { \
- char __b[32]; \
- char *__t; \
- _zend_print##func##_to_buf (__b + sizeof(__b) - 1, (num), vartype, __t); \
- smart_str_appendl_ex((dest), __t, __b + sizeof(__b) - 1 - __t, (type)); \
-} while (0)
-
-#define smart_str_append_unsigned_ex(dest, num, type) \
- smart_str_append_generic_ex((dest), (num), (type), zend_ulong, _unsigned)
-
-#define smart_str_append_long_ex(dest, num, type) \
- smart_str_append_generic_ex((dest), (num), (type), zend_ulong, _signed)
-
-#define smart_str_append_off_t_ex(dest, num, type) \
- smart_str_append_generic_ex((dest), (num), (type), zend_off_t, _signed)
-
-#define smart_str_append_ex(dest, src, what) do { \
- if ((src)->s && (src)->s->len) { \
- smart_str_appendl_ex((dest), (src)->s->val, (src)->s->len, (what)); \
- } \
-} while(0)
-
-#define smart_str_setl(dest, src, nlen) do { \
- smart_str_free((dest)); \
- smart_str_appendl_ex((dest), (src), (nlen), 0); \
-} while (0)
-
-#define smart_str_sets(dest, src) \
- smart_str_setl((dest), (src), strlen(src));
-
-#endif
diff --git a/ext/standard/php_smart_str_public.h b/ext/standard/php_smart_str_public.h
deleted file mode 100644
index 7ce299e442..0000000000
--- a/ext/standard/php_smart_str_public.h
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- +----------------------------------------------------------------------+
- | PHP Version 5 |
- +----------------------------------------------------------------------+
- | Copyright (c) 1997-2014 The PHP Group |
- +----------------------------------------------------------------------+
- | This source file is subject to version 3.01 of the PHP license, |
- | that is bundled with this package in the file LICENSE, and is |
- | available through the world-wide-web at the following url: |
- | http://www.php.net/license/3_01.txt |
- | If you did not receive a copy of the PHP license and are unable to |
- | obtain it through the world-wide-web, please send a note to |
- | license@php.net so we can mail you a copy immediately. |
- +----------------------------------------------------------------------+
- | Author: Sascha Schumann <sascha@schumann.cx> |
- +----------------------------------------------------------------------+
- */
-
-/* $Id$ */
-
-#ifndef PHP_SMART_STR_PUBLIC_H
-#define PHP_SMART_STR_PUBLIC_H
-
-#include <sys/types.h>
-
-typedef struct {
- zend_string *s;
- size_t a;
-} smart_str;
-
-#endif
diff --git a/ext/standard/php_smart_string.h b/ext/standard/php_smart_string.h
index 91530d94d3..e052574a34 100644
--- a/ext/standard/php_smart_string.h
+++ b/ext/standard/php_smart_string.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -89,8 +89,6 @@
smart_string_append_ex((dest), (src), 0)
#define smart_string_append_long(dest, val) \
smart_string_append_long_ex((dest), (val), 0)
-#define smart_string_append_off_t(dest, val) \
- smart_string_append_off_t_ex((dest), (val), 0)
#define smart_string_append_unsigned(dest, val) \
smart_string_append_unsigned_ex((dest), (val), 0)
@@ -119,33 +117,17 @@
__dest->len = __nl; \
} while (0)
-static inline char *smart_string_print_long(char *buf, zend_long num) {
- char *r;
- _zend_print_signed_to_buf(buf, num, unsigned long, r);
- return r;
-}
-
-static inline char *smart_string_print_unsigned(char *buf, zend_long num) {
- char *r;
- _zend_print_unsigned_to_buf(buf, num, unsigned long, r);
- return r;
-}
-
#define smart_string_append_generic_ex(dest, num, type, vartype, func) do { \
char __b[32]; \
- char *__t; \
- _zend_print##func##_to_buf(__b + sizeof(__b) - 1, (num), vartype, __t); \
+ char *__t = zend_print##func##_to_buf(__b + sizeof(__b) - 1, (num)); \
smart_string_appendl_ex((dest), __t, __b + sizeof(__b) - 1 - __t, (type)); \
} while (0)
#define smart_string_append_unsigned_ex(dest, num, type) \
- smart_string_append_generic_ex((dest), (num), (type), unsigned long, _unsigned)
+ smart_string_append_generic_ex((dest), (num), (type), zend_ulong, _ulong)
#define smart_string_append_long_ex(dest, num, type) \
- smart_string_append_generic_ex((dest), (num), (type), unsigned long, _signed)
-
-#define smart_string_append_off_t_ex(dest, num, type) \
- smart_string_append_generic_ex((dest), (num), (type), off_t, _signed)
+ smart_string_append_generic_ex((dest), (num), (type), zend_ulong, _long)
#define smart_string_append_ex(dest, src, what) \
smart_string_appendl_ex((dest), ((smart_string *)(src))->c, \
diff --git a/ext/standard/php_smart_string_public.h b/ext/standard/php_smart_string_public.h
index 215f182224..d4cd1180a4 100644
--- a/ext/standard/php_smart_string_public.h
+++ b/ext/standard/php_smart_string_public.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_standard.h b/ext/standard/php_standard.h
index d7476cb397..5f1716d849 100644
--- a/ext/standard/php_standard.h
+++ b/ext/standard/php_standard.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_string.h b/ext/standard/php_string.h
index bb173ee85a..9e872222fd 100644
--- a/ext/standard/php_string.h
+++ b/ext/standard/php_string.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_type.h b/ext/standard/php_type.h
index 8b71f87e5e..e6d8152b1b 100644
--- a/ext/standard/php_type.h
+++ b/ext/standard/php_type.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_uuencode.h b/ext/standard/php_uuencode.h
index f1dda2de45..0c8ceb72a3 100644
--- a/ext/standard/php_uuencode.h
+++ b/ext/standard/php_uuencode.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/php_var.h b/ext/standard/php_var.h
index 2dc13f4012..23225cdc42 100644
--- a/ext/standard/php_var.h
+++ b/ext/standard/php_var.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -22,7 +22,7 @@
#define PHP_VAR_H
#include "ext/standard/basic_functions.h"
-#include "ext/standard/php_smart_str_public.h"
+#include "zend_smart_str_public.h"
PHP_FUNCTION(var_dump);
PHP_FUNCTION(var_export);
@@ -38,7 +38,10 @@ PHPAPI void php_var_export_ex(zval *struc, int level, smart_str *buf TSRMLS_DC);
PHPAPI void php_debug_zval_dump(zval *struc, int level TSRMLS_DC);
-typedef HashTable* php_serialize_data_t;
+struct php_serialize_data {
+ HashTable ht;
+ uint32_t n;
+};
struct php_unserialize_data {
void *first;
@@ -47,71 +50,67 @@ struct php_unserialize_data {
void *last_dtor;
};
-typedef struct php_unserialize_data* php_unserialize_data_t;
+typedef struct php_serialize_data *php_serialize_data_t;
+typedef struct php_unserialize_data *php_unserialize_data_t;
-PHPAPI void php_var_serialize(smart_str *buf, zval *struc, php_serialize_data_t *var_hash TSRMLS_DC);
+PHPAPI void php_var_serialize(smart_str *buf, zval *struc, php_serialize_data_t *data TSRMLS_DC);
PHPAPI int php_var_unserialize(zval *rval, const unsigned char **p, const unsigned char *max, php_unserialize_data_t *var_hash TSRMLS_DC);
PHPAPI int php_var_unserialize_ref(zval *rval, const unsigned char **p, const unsigned char *max, php_unserialize_data_t *var_hash TSRMLS_DC);
PHPAPI int php_var_unserialize_intern(zval *rval, const unsigned char **p, const unsigned char *max, php_unserialize_data_t *var_hash TSRMLS_DC);
-#define PHP_VAR_SERIALIZE_INIT(var_hash_ptr) \
+#define PHP_VAR_SERIALIZE_INIT(d) \
do { \
/* fprintf(stderr, "SERIALIZE_INIT == lock: %u, level: %u\n", BG(serialize_lock), BG(serialize).level); */ \
if (BG(serialize_lock) || !BG(serialize).level) { \
- ALLOC_HASHTABLE(var_hash_ptr); \
- zend_hash_init((var_hash_ptr), 16, NULL, NULL, 0); \
+ (d) = (php_serialize_data_t) emalloc(sizeof(struct php_serialize_data)); \
+ zend_hash_init(&(d)->ht, 16, NULL, ZVAL_PTR_DTOR, 0); \
+ (d)->n = 0; \
if (!BG(serialize_lock)) { \
- BG(serialize).var_hash = (void *)(var_hash_ptr); \
+ BG(serialize).data = d; \
BG(serialize).level = 1; \
} \
} else { \
- (var_hash_ptr) = (php_serialize_data_t)BG(serialize).var_hash; \
+ (d) = BG(serialize).data; \
++BG(serialize).level; \
} \
} while(0)
-#define PHP_VAR_SERIALIZE_DESTROY(var_hash_ptr) \
+#define PHP_VAR_SERIALIZE_DESTROY(d) \
do { \
/* fprintf(stderr, "SERIALIZE_DESTROY == lock: %u, level: %u\n", BG(serialize_lock), BG(serialize).level); */ \
- if (BG(serialize_lock) || !BG(serialize).level) { \
- zend_hash_destroy((var_hash_ptr)); \
- FREE_HASHTABLE(var_hash_ptr); \
- } else { \
- if (!--BG(serialize).level) { \
- zend_hash_destroy((php_serialize_data_t)BG(serialize).var_hash); \
- FREE_HASHTABLE((php_serialize_data_t)BG(serialize).var_hash); \
- BG(serialize).var_hash = NULL; \
- } \
+ if (BG(serialize_lock) || BG(serialize).level == 1) { \
+ zend_hash_destroy(&(d)->ht); \
+ efree((d)); \
+ } \
+ if (!BG(serialize_lock) && !--BG(serialize).level) { \
+ BG(serialize).data = NULL; \
} \
} while (0)
-#define PHP_VAR_UNSERIALIZE_INIT(var_hash_ptr) \
+#define PHP_VAR_UNSERIALIZE_INIT(d) \
do { \
/* fprintf(stderr, "UNSERIALIZE_INIT == lock: %u, level: %u\n", BG(serialize_lock), BG(unserialize).level); */ \
if (BG(serialize_lock) || !BG(unserialize).level) { \
- (var_hash_ptr) = (php_unserialize_data_t)ecalloc(1, sizeof(struct php_unserialize_data)); \
+ (d) = (php_unserialize_data_t)ecalloc(1, sizeof(struct php_unserialize_data)); \
if (!BG(serialize_lock)) { \
- BG(unserialize).var_hash = (void *)(var_hash_ptr); \
+ BG(unserialize).data = (d); \
BG(unserialize).level = 1; \
} \
} else { \
- (var_hash_ptr) = (php_unserialize_data_t)BG(unserialize).var_hash; \
+ (d) = BG(unserialize).data; \
++BG(unserialize).level; \
} \
} while (0)
-#define PHP_VAR_UNSERIALIZE_DESTROY(var_hash_ptr) \
+#define PHP_VAR_UNSERIALIZE_DESTROY(d) \
do { \
/* fprintf(stderr, "UNSERIALIZE_DESTROY == lock: %u, level: %u\n", BG(serialize_lock), BG(unserialize).level); */ \
- if (BG(serialize_lock) || !BG(unserialize).level) { \
- var_destroy(&(var_hash_ptr)); \
- efree(var_hash_ptr); \
- } else { \
- if (!--BG(unserialize).level) { \
- var_destroy(&(var_hash_ptr)); \
- efree((var_hash_ptr)); \
- BG(unserialize).var_hash = NULL; \
- } \
+ if (BG(serialize_lock) || BG(unserialize).level == 1) { \
+ var_destroy(&(d)); \
+ efree((d)); \
+ } \
+ if (!BG(serialize_lock) && !--BG(unserialize).level) { \
+ BG(unserialize).data = NULL; \
} \
} while (0)
@@ -120,50 +119,4 @@ PHPAPI void var_push_dtor(php_unserialize_data_t *var_hash, zval *val);
PHPAPI void var_push_dtor_no_addref(php_unserialize_data_t *var_hashx, zval *rval);
PHPAPI void var_destroy(php_unserialize_data_t *var_hash);
-PHPAPI zend_class_entry *php_create_empty_class(char *class_name, int len);
-
-static inline int php_varname_check(char *name, int name_len, zend_bool silent TSRMLS_DC) /* {{{ */
-{
- if (name_len == sizeof("GLOBALS") - 1 && !memcmp(name, "GLOBALS", sizeof("GLOBALS") - 1)) {
- if (!silent) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Attempted GLOBALS variable overwrite");
- }
- return FAILURE;
- } else if (name[0] == '_' &&
- (
- (name_len == sizeof("_GET") - 1 && !memcmp(name, "_GET", sizeof("_GET") - 1)) ||
- (name_len == sizeof("_POST") - 1 && !memcmp(name, "_POST", sizeof("_POST") - 1)) ||
- (name_len == sizeof("_COOKIE") - 1 && !memcmp(name, "_COOKIE", sizeof("_COOKIE") - 1)) ||
- (name_len == sizeof("_ENV") - 1 && !memcmp(name, "_ENV", sizeof("_ENV") - 1)) ||
- (name_len == sizeof("_SERVER") - 1 && !memcmp(name, "_SERVER", sizeof("_SERVER") - 1)) ||
- (name_len == sizeof("_SESSION") - 1 && !memcmp(name, "_SESSION", sizeof("_SESSION") - 1)) ||
- (name_len == sizeof("_FILES") - 1 && !memcmp(name, "_FILES", sizeof("_FILES") - 1)) ||
- (name_len == sizeof("_REQUEST") -1 && !memcmp(name, "_REQUEST", sizeof("_REQUEST") - 1))
- )
- ) {
- if (!silent) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Attempted super-global (%s) variable overwrite", name);
- }
- return FAILURE;
- } else if (name[0] == 'H' &&
- (
- (name_len == sizeof("HTTP_POST_VARS") - 1 && !memcmp(name, "HTTP_POST_VARS", sizeof("HTTP_POST_VARS") - 1)) ||
- (name_len == sizeof("HTTP_GET_VARS") - 1 && !memcmp(name, "HTTP_GET_VARS", sizeof("HTTP_GET_VARS") - 1)) ||
- (name_len == sizeof("HTTP_COOKIE_VARS") - 1 && !memcmp(name, "HTTP_COOKIE_VARS", sizeof("HTTP_COOKIE_VARS") - 1)) ||
- (name_len == sizeof("HTTP_ENV_VARS") - 1 && !memcmp(name, "HTTP_ENV_VARS", sizeof("HTTP_ENV_VARS") - 1)) ||
- (name_len == sizeof("HTTP_SERVER_VARS") - 1 && !memcmp(name, "HTTP_SERVER_VARS", sizeof("HTTP_SERVER_VARS") - 1)) ||
- (name_len == sizeof("HTTP_SESSION_VARS") - 1 && !memcmp(name, "HTTP_SESSION_VARS", sizeof("HTTP_SESSION_VARS") - 1)) ||
- (name_len == sizeof("HTTP_RAW_POST_DATA") - 1 && !memcmp(name, "HTTP_RAW_POST_DATA", sizeof("HTTP_RAW_POST_DATA") - 1)) ||
- (name_len == sizeof("HTTP_POST_FILES") - 1 && !memcmp(name, "HTTP_POST_FILES", sizeof("HTTP_POST_FILES") - 1))
- )
- ) {
- if (!silent) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "Attempted long input array (%s) overwrite", name);
- }
- return FAILURE;
- }
- return SUCCESS;
-}
-/* }}} */
-
#endif /* PHP_VAR_H */
diff --git a/ext/standard/php_versioning.h b/ext/standard/php_versioning.h
index b3ea4f8f4d..3e34b8f8be 100644
--- a/ext/standard/php_versioning.h
+++ b/ext/standard/php_versioning.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/proc_open.c b/ext/standard/proc_open.c
index 8f79fffdf8..66c0c2e7e3 100644
--- a/ext/standard/proc_open.c
+++ b/ext/standard/proc_open.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/proc_open.h b/ext/standard/proc_open.h
index 8545f201f2..955cca2e3d 100644
--- a/ext/standard/proc_open.h
+++ b/ext/standard/proc_open.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/quot_print.c b/ext/standard/quot_print.c
index 8abccaf820..c7eddc576b 100644
--- a/ext/standard/quot_print.c
+++ b/ext/standard/quot_print.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/quot_print.h b/ext/standard/quot_print.h
index 7055d05717..99d3db8451 100644
--- a/ext/standard/quot_print.h
+++ b/ext/standard/quot_print.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/rand.c b/ext/standard/rand.c
index fdc86632cd..55388e3c13 100644
--- a/ext/standard/rand.c
+++ b/ext/standard/rand.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/scanf.c b/ext/standard/scanf.c
index 83fd551c19..62437831bb 100644
--- a/ext/standard/scanf.c
+++ b/ext/standard/scanf.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/scanf.h b/ext/standard/scanf.h
index 8d5fee22e1..ddb9803512 100644
--- a/ext/standard/scanf.h
+++ b/ext/standard/scanf.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/sha1.c b/ext/standard/sha1.c
index 8a05f50416..249828fb3d 100644
--- a/ext/standard/sha1.c
+++ b/ext/standard/sha1.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -46,10 +46,10 @@ PHP_FUNCTION(sha1)
sha1str[0] = '\0';
PHP_SHA1Init(&context);
- PHP_SHA1Update(&context, arg->val, arg->len);
+ PHP_SHA1Update(&context, (unsigned char *) arg->val, arg->len);
PHP_SHA1Final(digest, &context);
if (raw_output) {
- RETURN_STRINGL(digest, 20);
+ RETURN_STRINGL((char *) digest, 20);
} else {
make_digest_ex(sha1str, digest, 20);
RETVAL_STRING(sha1str);
@@ -71,7 +71,7 @@ PHP_FUNCTION(sha1_file)
unsigned char buf[1024];
unsigned char digest[20];
PHP_SHA1_CTX context;
- int n;
+ size_t n;
php_stream *stream;
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "p|b", &arg, &arg_len, &raw_output) == FAILURE) {
@@ -85,7 +85,7 @@ PHP_FUNCTION(sha1_file)
PHP_SHA1Init(&context);
- while ((n = php_stream_read(stream, buf, sizeof(buf))) > 0) {
+ while ((n = php_stream_read(stream, (char *) buf, sizeof(buf))) > 0) {
PHP_SHA1Update(&context, buf, n);
}
@@ -93,12 +93,8 @@ PHP_FUNCTION(sha1_file)
php_stream_close(stream);
- if (n<0) {
- RETURN_FALSE;
- }
-
if (raw_output) {
- RETURN_STRINGL(digest, 20);
+ RETURN_STRINGL((char *) digest, 20);
} else {
make_digest_ex(sha1str, digest, 20);
RETVAL_STRING(sha1str);
diff --git a/ext/standard/sha1.h b/ext/standard/sha1.h
index f852386a62..14787892e7 100644
--- a/ext/standard/sha1.h
+++ b/ext/standard/sha1.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/soundex.c b/ext/standard/soundex.c
index ede06637fa..feb9a6780e 100644
--- a/ext/standard/soundex.c
+++ b/ext/standard/soundex.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/streamsfuncs.c b/ext/standard/streamsfuncs.c
index 5557ba1356..f864994d28 100644
--- a/ext/standard/streamsfuncs.c
+++ b/ext/standard/streamsfuncs.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/streamsfuncs.h b/ext/standard/streamsfuncs.h
index 926cf2d5b5..a65f86e3a4 100644
--- a/ext/standard/streamsfuncs.h
+++ b/ext/standard/streamsfuncs.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/string.c b/ext/standard/string.c
index 0c41249473..4a37f7a5b3 100644
--- a/ext/standard/string.c
+++ b/ext/standard/string.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -56,7 +56,7 @@
#include "zend_execute.h"
#include "php_globals.h"
#include "basic_functions.h"
-#include "php_smart_str.h"
+#include "zend_smart_str.h"
#include <Zend/zend_exceptions.h>
#ifdef ZTS
#include "TSRM.h"
@@ -780,7 +780,7 @@ static inline int php_charmask(unsigned char *input, size_t len, char *mask TSRM
*/
PHPAPI char *php_trim(char *c, size_t len, char *what, size_t what_len, zval *return_value, int mode TSRMLS_DC)
{
- register zend_long i;
+ register size_t i;
size_t trimmed = 0;
char mask[256];
@@ -802,12 +802,15 @@ PHPAPI char *php_trim(char *c, size_t len, char *what, size_t what_len, zval *re
c += trimmed;
}
if (mode & 2) {
- for (i = len - 1; i >= 0; i--) {
- if (mask[(unsigned char)c[i]]) {
- len--;
- } else {
- break;
- }
+ if (len > 0) {
+ i = len - 1;
+ do {
+ if (mask[(unsigned char)c[i]]) {
+ len--;
+ } else {
+ break;
+ }
+ } while (i-- != 0);
}
}
@@ -1147,7 +1150,7 @@ PHPAPI void php_implode(zval *delim, zval *arr, zval *return_value TSRMLS_DC)
again:
switch (Z_TYPE_P(tmp)) {
case IS_STRING:
- smart_str_appendl(&implstr, Z_STRVAL_P(tmp), Z_STRLEN_P(tmp));
+ smart_str_append(&implstr, Z_STR_P(tmp));
break;
case IS_LONG:
@@ -1176,14 +1179,14 @@ again:
default:
str = zval_get_string(tmp);
- smart_str_appendl(&implstr, str->val, str->len);
+ smart_str_append(&implstr, str);
zend_string_release(str);
break;
}
if (++i != numelems) {
- smart_str_appendl(&implstr, Z_STRVAL_P(delim), Z_STRLEN_P(delim));
+ smart_str_append(&implstr, Z_STR_P(delim));
}
} ZEND_HASH_FOREACH_END();
@@ -1810,7 +1813,7 @@ PHP_FUNCTION(strpos)
ZEND_PARSE_PARAMETERS_END();
#endif
- if (offset < 0 || offset > haystack->len) {
+ if (offset < 0 || (size_t)offset > haystack->len) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Offset not contained in string");
RETURN_FALSE;
}
@@ -1860,7 +1863,7 @@ PHP_FUNCTION(stripos)
return;
}
- if (offset < 0 || offset > haystack->len) {
+ if (offset < 0 || (size_t)offset > haystack->len) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Offset not contained in string");
RETURN_FALSE;
}
@@ -1948,20 +1951,20 @@ PHP_FUNCTION(strrpos)
}
if (offset >= 0) {
- if (offset > haystack->len) {
+ if ((size_t)offset > haystack->len) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Offset is greater than the length of haystack string");
RETURN_FALSE;
}
- p = haystack->val + offset;
+ p = haystack->val + (size_t)offset;
e = haystack->val + haystack->len - needle_len;
} else {
- if (offset < -INT_MAX || -offset > haystack->len) {
+ if (offset < -INT_MAX || (size_t)(-offset) > haystack->len) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Offset is greater than the length of haystack string");
RETURN_FALSE;
}
p = haystack->val;
- if (needle_len > -offset) {
+ if (needle_len > (size_t)(-offset)) {
e = haystack->val + haystack->len - needle_len;
} else {
e = haystack->val + haystack->len + offset;
@@ -2026,7 +2029,7 @@ PHP_FUNCTION(strripos)
/* Single character search can shortcut memcmps
Can also avoid tolower emallocs */
if (offset >= 0) {
- if (offset > haystack->len) {
+ if ((size_t)offset > haystack->len) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Offset is greater than the length of haystack string");
RETURN_FALSE;
}
@@ -2034,7 +2037,7 @@ PHP_FUNCTION(strripos)
e = haystack->val + haystack->len - 1;
} else {
p = haystack->val;
- if (offset < -INT_MAX || -offset > haystack->len) {
+ if (offset < -INT_MAX || (size_t)(-offset) > haystack->len) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Offset is greater than the length of haystack string");
RETURN_FALSE;
}
@@ -2057,7 +2060,7 @@ PHP_FUNCTION(strripos)
php_strtolower(haystack_dup, haystack->len);
if (offset >= 0) {
- if (offset > haystack->len) {
+ if ((size_t)offset > haystack->len) {
efree(needle_dup);
efree(haystack_dup);
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Offset is greater than the length of haystack string");
@@ -2066,14 +2069,14 @@ PHP_FUNCTION(strripos)
p = haystack_dup + offset;
e = haystack_dup + haystack->len - needle_len;
} else {
- if (offset < -INT_MAX || -offset > haystack->len) {
+ if (offset < -INT_MAX || (size_t)(-offset) > haystack->len) {
efree(needle_dup);
efree(haystack_dup);
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Offset is greater than the length of haystack string");
RETURN_FALSE;
}
p = haystack_dup;
- if (needle_len > -offset) {
+ if (needle_len > (size_t)(-offset)) {
e = haystack_dup + haystack->len - needle_len;
} else {
e = haystack_dup + haystack->len + offset;
@@ -2197,7 +2200,7 @@ PHP_FUNCTION(chunk_split)
RETURN_FALSE;
}
- if (chunklen > str->len) {
+ if ((size_t)chunklen > str->len) {
/* to maintain BC, we must return original string + ending */
result = zend_string_alloc(endlen + str->len, 0);
memcpy(result->val, str->val, str->len);
@@ -2210,7 +2213,7 @@ PHP_FUNCTION(chunk_split)
RETURN_EMPTY_STRING();
}
- result = php_chunk_split(str->val, str->len, end, endlen, chunklen);
+ result = php_chunk_split(str->val, str->len, end, endlen, (size_t)chunklen);
if (result) {
RETURN_STR(result);
@@ -2242,7 +2245,7 @@ PHP_FUNCTION(substr)
#endif
if (argc > 2) {
- if ((l < 0 && -l > str->len)) {
+ if ((l < 0 && (size_t)(-l) > str->len)) {
RETURN_FALSE;
} else if (l > (zend_long)str->len) {
l = str->len;
@@ -2556,7 +2559,7 @@ PHP_FUNCTION(substr_replace)
if (str_index) {
zval tmp;
- ZVAL_STR(&tmp, result);
+ ZVAL_NEW_STR(&tmp, result);
zend_symtable_update(Z_ARRVAL_P(return_value), str_index, &tmp);
} else {
add_index_str(return_value, num_index, result);
@@ -2904,7 +2907,7 @@ static void php_strtr_array(zval *return_value, char *str, size_t slen, HashTabl
entry = zend_hash_str_find(pats, key, len);
if (entry != NULL) {
zend_string *str = zval_get_string(entry);
- smart_str_appendl(&result, str->val, str->len);
+ smart_str_append(&result, str);
pos += len;
found = 1;
zend_string_release(str);
@@ -2929,7 +2932,7 @@ static void php_strtr_array(zval *return_value, char *str, size_t slen, HashTabl
entry = zend_hash_str_find(pats, key, len);
if (entry != NULL) {
zend_string *str = zval_get_string(entry);
- smart_str_appendl(&result, str->val, str->len);
+ smart_str_append(&result, str);
pos += len;
found = 1;
zend_string_release(str);
@@ -3794,7 +3797,7 @@ static void php_str_replace_common(INTERNAL_FUNCTION_PARAMETERS, int case_sensit
zval result;
zend_string *string_key;
zend_ulong num_key;
- zend_long count = 0;
+ size_t count = 0;
int argc = ZEND_NUM_ARGS();
#ifndef FAST_ZPP
@@ -3980,7 +3983,7 @@ static void php_hebrev(INTERNAL_FUNCTION_PARAMETERS, int convert_newlines)
while (1) {
char_count=0;
- while ((!max_chars || max_chars > 0 && char_count < max_chars) && begin > 0) {
+ while ((!max_chars || (max_chars > 0 && char_count < max_chars)) && begin > 0) {
char_count++;
begin--;
if (begin <= 0 || _isnewline(heb_str[begin])) {
@@ -4156,7 +4159,7 @@ PHP_FUNCTION(strip_tags)
if (allow != NULL) {
convert_to_string_ex(allow);
// TODO: reimplement to avoid reallocation ???
- if (IS_INTERNED(Z_STR_P(allow))) {
+ if (!Z_REFCOUNTED_P(allow)) {
allowed_tags = estrndup(Z_STRVAL_P(allow), Z_STRLEN_P(allow));
allowed_tags_len = Z_STRLEN_P(allow);
} else {
@@ -4169,7 +4172,7 @@ PHP_FUNCTION(strip_tags)
buf->len = php_strip_tags_ex(buf->val, str->len, NULL, allowed_tags, allowed_tags_len, 0);
// TODO: reimplement to avoid reallocation ???
- if (allow && IS_INTERNED(Z_STR_P(allow))) {
+ if (allow && !Z_REFCOUNTED_P(allow)) {
efree(allowed_tags);
}
RETURN_STR(buf);
@@ -4999,7 +5002,7 @@ PHP_FUNCTION(substr_count)
RETURN_FALSE;
}
- if (offset > haystack_len) {
+ if ((size_t)offset > haystack_len) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Offset value " ZEND_LONG_FMT " exceeds string length", offset);
RETURN_FALSE;
}
@@ -5058,7 +5061,7 @@ PHP_FUNCTION(str_pad)
/* If resulting string turns out to be shorter than input string,
we simply copy the input and return. */
- if (pad_length < 0 || pad_length <= input->len) {
+ if (pad_length < 0 || (size_t)pad_length <= input->len) {
RETURN_STRINGL(input->val, input->len);
}
@@ -5347,7 +5350,7 @@ PHP_FUNCTION(str_split)
}
- if (0 == str->len || split_length >= str->len) {
+ if (0 == str->len || (size_t)split_length >= str->len) {
array_init_size(return_value, 1);
add_next_index_stringl(return_value, str->val, str->len);
return;
@@ -5424,7 +5427,7 @@ PHP_FUNCTION(substr_compare)
offset = (offset < 0) ? 0 : offset;
}
- if (offset >= s1->len) {
+ if ((size_t)offset >= s1->len) {
php_error_docref(NULL TSRMLS_CC, E_WARNING, "The start position cannot exceed initial string length");
RETURN_FALSE;
}
diff --git a/ext/standard/strnatcmp.c b/ext/standard/strnatcmp.c
index face191a6e..de6f727343 100644
--- a/ext/standard/strnatcmp.c
+++ b/ext/standard/strnatcmp.c
@@ -108,8 +108,9 @@ PHPAPI int strnatcmp_ex(char const *a, size_t a_len, char const *b, size_t b_len
int fractional, result;
short leading = 1;
- if (a_len == 0 || b_len == 0)
- return a_len - b_len;
+ if (a_len == 0 || b_len == 0) {
+ return (a_len == b_len ? 0 : (a_len > b_len ? 1 : -1));
+ }
ap = a;
bp = b;
diff --git a/ext/standard/syslog.c b/ext/standard/syslog.c
index 900b118a4e..036c189e75 100644
--- a/ext/standard/syslog.c
+++ b/ext/standard/syslog.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/tests/file/bug41655_1-win32.phpt b/ext/standard/tests/file/bug41655_1-win32.phpt
new file mode 100644
index 0000000000..631d91079b
--- /dev/null
+++ b/ext/standard/tests/file/bug41655_1-win32.phpt
@@ -0,0 +1,22 @@
+--TEST--
+Bug #41655 (open_basedir bypass via glob()) 1/2
+--SKIPIF--
+<?php
+if (substr(PHP_OS, 0, 3) != 'WIN') {
+ die('skip only for Windows');
+}
+?>
+--CREDITS--
+Dave Kelsey <d_kelsey@uk.ibm.com>
+--INI--
+open_basedir=/tmp
+--FILE--
+<?php
+$a=glob("./*.jpeg");
+var_dump($a);
+echo "Done\n";
+?>
+--EXPECT--
+array(0) {
+}
+Done
diff --git a/ext/standard/tests/file/bug41655_1.phpt b/ext/standard/tests/file/bug41655_1.phpt
index 62d64dfb1e..e4466821f9 100644
--- a/ext/standard/tests/file/bug41655_1.phpt
+++ b/ext/standard/tests/file/bug41655_1.phpt
@@ -1,5 +1,11 @@
--TEST--
Bug #41655 (open_basedir bypass via glob()) 1/2
+--SKIPIF--
+<?php
+if (substr(PHP_OS, 0, 3) == 'WIN') {
+ die('skip not for Windows');
+}
+?>
--CREDITS--
Dave Kelsey <d_kelsey@uk.ibm.com>
--INI--
@@ -12,4 +18,4 @@ echo "Done\n";
?>
--EXPECT--
bool(false)
-Done \ No newline at end of file
+Done
diff --git a/ext/standard/tests/file/bug65701.phpt b/ext/standard/tests/file/bug65701.phpt
index 2b1b5d491d..42d8d3e628 100644
--- a/ext/standard/tests/file/bug65701.phpt
+++ b/ext/standard/tests/file/bug65701.phpt
@@ -6,7 +6,9 @@ Boro Sitnikovski <buritomath@yahoo.com>
<?php
$file_path = dirname(__FILE__) . "/bug65701/";
-mkdir($file_path);
+if (!is_dir($file_path)) {
+ mkdir($file_path);
+}
$src = $file_path . '/srcbug65701_file.txt';
$dst = tempnam($file_path, 'dstbug65701_file.txt');
diff --git a/ext/standard/tests/file/file_put_contents_variation5.phpt b/ext/standard/tests/file/file_put_contents_variation5.phpt
index 4ecb5213ac..baaa7a65d9 100644
--- a/ext/standard/tests/file/file_put_contents_variation5.phpt
+++ b/ext/standard/tests/file/file_put_contents_variation5.phpt
@@ -48,4 +48,3 @@ File written in working directory
File written in working directory
File written in working directory
===DONE===
-
diff --git a/ext/standard/tests/serialize/counting_of_references.phpt b/ext/standard/tests/serialize/counting_of_references.phpt
new file mode 100644
index 0000000000..e7ead96759
--- /dev/null
+++ b/ext/standard/tests/serialize/counting_of_references.phpt
@@ -0,0 +1,14 @@
+--TEST--
+References are not counted twice
+--FILE--
+<?php
+
+$ref1 = 1;
+$ref2 = 2;
+
+$arr = [&$ref1, &$ref1, &$ref2, &$ref2];
+var_dump(serialize($arr));
+
+?>
+--EXPECT--
+string(38) "a:4:{i:0;i:1;i:1;R:2;i:2;i:2;i:3;R:3;}"
diff --git a/ext/standard/tests/streams/proc_open_bug51800.phpt b/ext/standard/tests/streams/proc_open_bug51800.phpt
new file mode 100644
index 0000000000..53cafd8555
--- /dev/null
+++ b/ext/standard/tests/streams/proc_open_bug51800.phpt
@@ -0,0 +1,95 @@
+--TEST--
+Bug #51800 proc_open on Windows hangs forever
+--SKIPIF--
+<?php
+ echo 'skip expected to fail or take too long';
+ if (getenv("SKIP_SLOW_TESTS")) {
+ die("skip slow test");
+ }
+?>
+--XFAIL--
+pipes have to be read/written simultaneously
+--FILE--
+<?php
+/* This is the wrong way to do it. The parent will block till it has read all the STDIN.
+The smaller the pipe buffer is, the longer it will take. It might even pass at the end,
+after taking inappropriately long. Pipes have to be read simultaneously in smaller chunks,
+so then the pipe buffer is emptied more often and the child has chance to continue its
+write. The behaviour might look some better if write/read in a separate thread, however
+this is much more resource greedy and complexer to integrate into the user script. */
+
+$callee = dirname(__FILE__) . "/process_proc_open_bug51800.php";
+$php = PHP_BINARY;
+$cmd = "$php $callee";
+
+$status;
+$stdout = "";
+$stderr = "";
+$pipes = array();
+
+$descriptors = array(
+ 0 => array("pipe", "rb"), // stdin
+ 1 => array("pipe", "wb"), // stdout
+ 2 => array("pipe", "wb") // stderr
+ );
+
+/* create the proc file */
+$r = file_put_contents($callee, '<?php
+
+$how_much = 10000;
+
+$data0 = str_repeat("a", $how_much);
+$data1 = str_repeat("b", $how_much);
+fwrite(STDOUT, $data0);
+fwrite(STDERR, $data1);
+
+exit(0);
+');
+
+if (!$r) {
+ die("couldn't create helper script '$callee'");
+}
+
+$process = proc_open($cmd, $descriptors, $pipes);
+
+if (is_resource($process))
+{
+ fclose($pipes[0]);
+
+ while (!feof($pipes[1]))
+ $stdout .= fread($pipes[1], 1024);
+ fclose($pipes[1]);
+
+ while (!feof($pipes[2]))
+ $stderr .= fread($pipes[2], 1024);
+ fclose($pipes[2]);
+
+ $status = proc_close($process);
+}
+
+var_dump(array(
+ "status" => $status,
+ "stdout" => $stdout,
+ "stderr" => $stderr,
+), strlen($stdout), strlen($stderr));
+
+?>
+===DONE===
+--CLEAN--
+<?php
+$callee = dirname(__FILE__) . "/process_proc_open_bug51800.php";
+unlink($callee);
+?>
+--EXPECTF--
+array(3) {
+ ["status"]=>
+ int(0)
+ ["stdout"]=>
+ string(10000) "a%s"
+ ["stderr"]=>
+ string(10000) "b%s"
+}
+int(10000)
+int(10000)
+===DONE===
+
diff --git a/ext/standard/tests/streams/proc_open_bug51800_right.phpt b/ext/standard/tests/streams/proc_open_bug51800_right.phpt
new file mode 100644
index 0000000000..b14fed2e5d
--- /dev/null
+++ b/ext/standard/tests/streams/proc_open_bug51800_right.phpt
@@ -0,0 +1,78 @@
+--TEST--
+Bug #51800 proc_open on Windows hangs forever, the right way to do it
+--FILE--
+<?php
+$callee = dirname(__FILE__) . "/process_proc_open_bug51800_right.php";
+$php = PHP_BINARY;
+$cmd = "$php $callee";
+
+$status;
+$stdout = "";
+$stderr = "";
+$pipes = array();
+
+$descriptors = array(
+ 0 => array("pipe", "rb"), // stdin
+ 1 => array("pipe", "wb"), // stdout
+ 2 => array("pipe", "wb") // stderr
+ );
+
+/* create the proc file */
+$r = file_put_contents($callee, '<?php
+
+$how_much = 10000;
+
+$data0 = str_repeat("a", $how_much);
+$data1 = str_repeat("b", $how_much);
+fwrite(STDOUT, $data0);
+fwrite(STDERR, $data1);
+
+exit(0);
+');
+
+if (!$r) {
+ die("couldn't create helper script '$callee'");
+}
+
+$process = proc_open($cmd, $descriptors, $pipes);
+
+if (is_resource($process))
+{
+ fclose($pipes[0]);
+
+ while (!feof($pipes[1]) || !feof($pipes[2])) {
+ $stdout .= fread($pipes[1], 1024);
+ $stderr .= fread($pipes[2], 1024);
+ }
+ fclose($pipes[1]);
+ fclose($pipes[2]);
+
+ $status = proc_close($process);
+}
+
+var_dump(array(
+ "status" => $status,
+ "stdout" => $stdout,
+ "stderr" => $stderr,
+), strlen($stdout), strlen($stderr));
+
+?>
+===DONE===
+--CLEAN--
+<?php
+$callee = dirname(__FILE__) . "/process_proc_open_bug51800_right.php";
+unlink($callee);
+?>
+--EXPECTF--
+array(3) {
+ ["status"]=>
+ int(0)
+ ["stdout"]=>
+ string(10000) "a%s"
+ ["stderr"]=>
+ string(10000) "b%s"
+}
+int(10000)
+int(10000)
+===DONE===
+
diff --git a/ext/standard/tests/streams/proc_open_bug51800_right2.phpt b/ext/standard/tests/streams/proc_open_bug51800_right2.phpt
new file mode 100644
index 0000000000..1e742745c1
--- /dev/null
+++ b/ext/standard/tests/streams/proc_open_bug51800_right2.phpt
@@ -0,0 +1,84 @@
+--TEST--
+Bug #51800 proc_open on Windows hangs forever, the right way to do it with more data
+--FILE--
+<?php
+$callee = dirname(__FILE__) . "/process_proc_open_bug51800_right2.php";
+$php = PHP_BINARY;
+$cmd = "$php $callee";
+
+$status;
+$stdout = "";
+$stderr = "";
+$pipes = array();
+
+$descriptors = array(
+ 0 => array("pipe", "rb"), // stdin
+ 1 => array("pipe", "wb"), // stdout
+ 2 => array("pipe", "wb") // stderr
+ );
+
+/* create the proc file */
+$r = file_put_contents($callee, '<?php
+$how_much = 1000000;
+
+$data0 = str_repeat("a", $how_much);
+$data1 = str_repeat("b", $how_much);
+$i0 = $i1 = 0;
+$step = 1024;
+
+while ($i0 < strlen($data0) && $i1 < strlen($data1)) {
+ fwrite(STDOUT, substr($data0, $i0, $step));
+ fwrite(STDERR, substr($data1, $i1, $step));
+ $i0 += $step;
+ $i1 += $step;
+}
+
+exit(0);
+');
+
+if (!$r) {
+ die("couldn't create helper script '$callee'");
+}
+
+$process = proc_open($cmd, $descriptors, $pipes);
+
+if (is_resource($process))
+{
+ fclose($pipes[0]);
+
+ while (!feof($pipes[1]) || !feof($pipes[2])) {
+ $stdout .= fread($pipes[1], 1024);
+ $stderr .= fread($pipes[2], 1024);
+ }
+ fclose($pipes[1]);
+ fclose($pipes[2]);
+
+ $status = proc_close($process);
+}
+
+var_dump(array(
+ "status" => $status,
+ "stdout" => $stdout,
+ "stderr" => $stderr,
+), strlen($stdout), strlen($stderr));
+
+?>
+===DONE===
+--CLEAN--
+<?php
+$callee = dirname(__FILE__) . "/process_proc_open_bug51800_right2.php";
+unlink($callee);
+?>
+--EXPECTF--
+array(3) {
+ ["status"]=>
+ int(0)
+ ["stdout"]=>
+ string(1000000) "a%s"
+ ["stderr"]=>
+ string(1000000) "b%s"
+}
+int(1000000)
+int(1000000)
+===DONE===
+
diff --git a/ext/standard/tests/streams/proc_open_bug60120.phpt b/ext/standard/tests/streams/proc_open_bug60120.phpt
new file mode 100644
index 0000000000..8768257a2e
--- /dev/null
+++ b/ext/standard/tests/streams/proc_open_bug60120.phpt
@@ -0,0 +1,71 @@
+--TEST--
+Bug #60120 proc_open hangs with stdin/out with 2048+ bytes
+--FILE--
+<?php
+error_reporting(E_ALL);
+
+if (substr(PHP_OS, 0, 3) == 'WIN') {
+ $cmd = PHP_BINARY . ' -n -r "fwrite(STDOUT, $in = file_get_contents(\'php://stdin\')); fwrite(STDERR, $in);"';
+} else {
+ $cmd = PHP_BINARY . ' -n -r \'fwrite(STDOUT, $in = file_get_contents("php://stdin")); fwrite(STDERR, $in);\'';
+}
+$descriptors = array(array('pipe', 'r'), array('pipe', 'w'), array('pipe', 'w'));
+$stdin = str_repeat('*', 1024 * 16) . '!';
+$stdin = str_repeat('*', 2049 );
+
+$options = array_merge(array('suppress_errors' => true, 'binary_pipes' => true, 'bypass_shell' => false));
+$process = proc_open($cmd, $descriptors, $pipes, getcwd(), array(), $options);
+
+foreach ($pipes as $pipe) {
+ stream_set_blocking($pipe, false);
+}
+$writePipes = array($pipes[0]);
+$stdinLen = strlen($stdin);
+$stdinOffset = 0;
+
+unset($pipes[0]);
+
+while ($pipes || $writePipes) {
+ $r = $pipes;
+ $w = $writePipes;
+ $e = null;
+ $n = stream_select($r, $w, $e, 60);
+
+ if (false === $n) {
+ break;
+ } elseif ($n === 0) {
+ proc_terminate($process);
+
+ }
+ if ($w) {
+ $written = fwrite($writePipes[0], (binary)substr($stdin, $stdinOffset), 8192);
+ if (false !== $written) {
+ $stdinOffset += $written;
+ }
+ if ($stdinOffset >= $stdinLen) {
+ fclose($writePipes[0]);
+ $writePipes = null;
+ }
+ }
+
+ foreach ($r as $pipe) {
+ $type = array_search($pipe, $pipes);
+ $data = fread($pipe, 8192);
+ var_dump($data);
+ if (false === $data || feof($pipe)) {
+ fclose($pipe);
+ unset($pipes[$type]);
+ }
+ }
+}
+
+
+?>
+===DONE===
+--EXPECTF--
+string(2049) "%s"
+string(2049) "%s"
+string(0) ""
+string(0) ""
+===DONE===
+
diff --git a/ext/standard/tests/streams/proc_open_bug64438.phpt b/ext/standard/tests/streams/proc_open_bug64438.phpt
new file mode 100644
index 0000000000..b3857d09d4
--- /dev/null
+++ b/ext/standard/tests/streams/proc_open_bug64438.phpt
@@ -0,0 +1,70 @@
+--TEST--
+Bug #64438 proc_open hangs with stdin/out with 4097+ bytes
+--FILE--
+<?php
+
+error_reporting(E_ALL);
+
+if (substr(PHP_OS, 0, 3) == 'WIN') {
+ $cmd = PHP_BINARY . ' -n -r "fwrite(STDOUT, $in = file_get_contents(\'php://stdin\')); fwrite(STDERR, $in);"';
+} else {
+ $cmd = PHP_BINARY . ' -n -r \'fwrite(STDOUT, $in = file_get_contents("php://stdin")); fwrite(STDERR, $in);\'';
+}
+$descriptors = array(array('pipe', 'r'), array('pipe', 'w'), array('pipe', 'w'));
+$stdin = str_repeat('*', 4097);
+
+$options = array_merge(array('suppress_errors' => true, 'binary_pipes' => true, 'bypass_shell' => false));
+$process = proc_open($cmd, $descriptors, $pipes, getcwd(), array(), $options);
+
+foreach ($pipes as $pipe) {
+ stream_set_blocking($pipe, false);
+}
+$writePipes = array($pipes[0]);
+$stdinLen = strlen($stdin);
+$stdinOffset = 0;
+
+unset($pipes[0]);
+
+while ($pipes || $writePipes) {
+ $r = $pipes;
+ $w = $writePipes;
+ $e = null;
+ $n = stream_select($r, $w, $e, 60);
+
+ if (false === $n) {
+ break;
+ } elseif ($n === 0) {
+ proc_terminate($process);
+
+ }
+ if ($w) {
+ $written = fwrite($writePipes[0], (binary)substr($stdin, $stdinOffset), 8192);
+ if (false !== $written) {
+ $stdinOffset += $written;
+ }
+ if ($stdinOffset >= $stdinLen) {
+ fclose($writePipes[0]);
+ $writePipes = null;
+ }
+ }
+
+ foreach ($r as $pipe) {
+ $type = array_search($pipe, $pipes);
+ $data = fread($pipe, 8192);
+ var_dump($data);
+ if (false === $data || feof($pipe)) {
+ fclose($pipe);
+ unset($pipes[$type]);
+ }
+ }
+}
+
+?>
+===DONE===
+--EXPECTF--
+string(4097) "%s"
+string(4097) "%s"
+string(0) ""
+string(0) ""
+===DONE===
+
diff --git a/ext/standard/tests/strings/setlocale_variation2.phpt b/ext/standard/tests/strings/setlocale_variation2.phpt
index 10ae22fe0c..5ebdfe8d50 100644
--- a/ext/standard/tests/strings/setlocale_variation2.phpt
+++ b/ext/standard/tests/strings/setlocale_variation2.phpt
@@ -20,9 +20,9 @@ echo "*** Testing setlocale() : usage variations ***\n";
function good_locale($locale) {
/**
- * Note: no_NO is a bogus locale and should not be used, see https://bugzilla.redhat.com/show_bug.cgi?id=532487
+ * Note: no_NO is a bogus locale and should not be used, see https://bugzilla.redhat.com/971416
**/
- return $locale !== 'tt_RU@iqtelif.UTF-8' && substr($locale, 0, 5) !== "no_NO";
+ return $locale !== 'tt_RU@iqtelif.UTF-8' && $locale !== 'no_NO.ISO-8859-1';
}
/* Prototype : array list_system_locales( void )
diff --git a/ext/standard/tests/strings/strnatcasecmp_variation1.phpt b/ext/standard/tests/strings/strnatcasecmp_variation1.phpt
index fb0fb79ae5..e74f6b73e9 100644
--- a/ext/standard/tests/strings/strnatcasecmp_variation1.phpt
+++ b/ext/standard/tests/strings/strnatcasecmp_variation1.phpt
@@ -48,8 +48,8 @@ str_dump($a, $b);
--EXPECT--
*** Testing strnatcasecmp() : variation ***
int(1)
-int(6)
-int(-2)
+int(1)
+int(-1)
int(-1)
int(0)
int(0)
diff --git a/ext/standard/type.c b/ext/standard/type.c
index b320d9e5c5..fa5cd4639e 100644
--- a/ext/standard/type.c
+++ b/ext/standard/type.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/uniqid.c b/ext/standard/uniqid.c
index 65cbcf12c3..1014f5d9ba 100644
--- a/ext/standard/uniqid.c
+++ b/ext/standard/uniqid.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/uniqid.h b/ext/standard/uniqid.h
index 0ea57fa52a..2247e8c2ee 100644
--- a/ext/standard/uniqid.h
+++ b/ext/standard/uniqid.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/url.c b/ext/standard/url.c
index 60ce808f4e..81f9b2ac9a 100644
--- a/ext/standard/url.c
+++ b/ext/standard/url.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/url.h b/ext/standard/url.h
index d23f0a1f17..4d7a1f5b56 100644
--- a/ext/standard/url.h
+++ b/ext/standard/url.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/url_scanner_ex.c b/ext/standard/url_scanner_ex.c
index 1f085f9c77..3d7aa985b8 100644
--- a/ext/standard/url_scanner_ex.c
+++ b/ext/standard/url_scanner_ex.c
@@ -2,7 +2,7 @@
#line 1 "ext/standard/url_scanner_ex.re"
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -42,7 +42,7 @@
#define url_scanner url_scanner_ex
-#include "php_smart_str.h"
+#include "zend_smart_str.h"
static void tag_dtor(zval *zv)
{
@@ -166,7 +166,7 @@ scan:
if (yych >= ';') goto yy4;
++YYCURSOR;
#line 125 "ext/standard/url_scanner_ex.re"
- { smart_str_append(dest, url); return; }
+ { smart_str_append_smart_str(dest, url); return; }
#line 171 "ext/standard/url_scanner_ex.c"
yy4:
++YYCURSOR;
@@ -195,17 +195,17 @@ done:
/* Don't modify URLs of the format "#mark" */
if (bash && bash - url->s->val == 0) {
- smart_str_append(dest, url);
+ smart_str_append_smart_str(dest, url);
return;
}
if (bash)
smart_str_appendl(dest, url->s->val, bash - url->s->val);
else
- smart_str_append(dest, url);
+ smart_str_append_smart_str(dest, url);
smart_str_appends(dest, sep);
- smart_str_append(dest, url_app);
+ smart_str_append_smart_str(dest, url_app);
if (bash)
smart_str_appendl(dest, bash, q - bash);
@@ -230,7 +230,7 @@ static inline void tag_arg(url_adapt_state_ex_t *ctx, char quotes, char type TSR
if (f) {
append_modified_url(&ctx->val, &ctx->result, &ctx->url_app, PG(arg_separator).output);
} else {
- smart_str_append(&ctx->result, &ctx->val);
+ smart_str_append_smart_str(&ctx->result, &ctx->val);
}
if (quotes)
smart_str_appendc(&ctx->result, type);
@@ -304,7 +304,7 @@ static void handle_form(STD_PARA)
}
if (doit)
- smart_str_append(&ctx->result, &ctx->form_app);
+ smart_str_append_smart_str(&ctx->result, &ctx->form_app);
}
}
@@ -958,7 +958,7 @@ static char *url_adapt_ext(const char *src, size_t srclen, size_t *newlen, zend_
}
smart_str_0(&ctx->result);
if (do_flush) {
- smart_str_appendl(&ctx->result, ctx->buf.s->val, ctx->buf.s->len);
+ smart_str_append(&ctx->result, ctx->buf.s);
*newlen += ctx->buf.s->len;
smart_str_free(&ctx->buf);
smart_str_free(&ctx->val);
@@ -1007,7 +1007,7 @@ static void php_url_scanner_output_handler(char *output, uint output_len, char *
} else if (BG(url_adapt_state_ex).url_app.s->len == 0) {
url_adapt_state_ex_t *ctx = &BG(url_adapt_state_ex);
if (ctx->buf.s && ctx->buf.s->len) {
- smart_str_appendl(&ctx->result, ctx->buf.s->val, ctx->buf.s->len);
+ smart_str_append(&ctx->result, ctx->buf.s);
smart_str_appendl(&ctx->result, output, output_len);
*handled_output = estrndup(ctx->result.s->val, ctx->result.s->len);
@@ -1048,12 +1048,12 @@ PHPAPI int php_url_scanner_add_var(char *name, int name_len, char *value, int va
smart_str_appendl(&BG(url_adapt_state_ex).url_app, name, name_len);
smart_str_appendc(&BG(url_adapt_state_ex).url_app, '=');
- smart_str_append(&BG(url_adapt_state_ex).url_app, &val);
+ smart_str_append_smart_str(&BG(url_adapt_state_ex).url_app, &val);
smart_str_appends(&BG(url_adapt_state_ex).form_app, "<input type=\"hidden\" name=\"");
smart_str_appendl(&BG(url_adapt_state_ex).form_app, name, name_len);
smart_str_appends(&BG(url_adapt_state_ex).form_app, "\" value=\"");
- smart_str_append(&BG(url_adapt_state_ex).form_app, &val);
+ smart_str_append_smart_str(&BG(url_adapt_state_ex).form_app, &val);
smart_str_appends(&BG(url_adapt_state_ex).form_app, "\" />");
if (urlencode) {
diff --git a/ext/standard/url_scanner_ex.h b/ext/standard/url_scanner_ex.h
index 0a7925e245..3c5b68c95b 100644
--- a/ext/standard/url_scanner_ex.h
+++ b/ext/standard/url_scanner_ex.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -31,7 +31,7 @@ PHPAPI char *php_url_scanner_adapt_single_url(const char *url, size_t urllen, co
PHPAPI int php_url_scanner_add_var(char *name, int name_len, char *value, int value_len, int urlencode TSRMLS_DC);
PHPAPI int php_url_scanner_reset_vars(TSRMLS_D);
-#include "php_smart_str_public.h"
+#include "zend_smart_str_public.h"
typedef struct {
/* Used by the mainloop of the scanner */
diff --git a/ext/standard/url_scanner_ex.re b/ext/standard/url_scanner_ex.re
index a2cb7ff8d9..2e74b1fb30 100644
--- a/ext/standard/url_scanner_ex.re
+++ b/ext/standard/url_scanner_ex.re
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -40,7 +40,7 @@
#define url_scanner url_scanner_ex
-#include "php_smart_str.h"
+#include "zend_smart_str.h"
static void tag_dtor(zval *zv)
{
@@ -122,7 +122,7 @@ static inline void append_modified_url(smart_str *url, smart_str *dest, smart_st
scan:
/*!re2c
- ":" { smart_str_append(dest, url); return; }
+ ":" { smart_str_append_smart_str(dest, url); return; }
"?" { sep = separator; goto scan; }
"#" { bash = p - 1; goto done; }
(any\[:?#])+ { goto scan; }
@@ -131,17 +131,17 @@ done:
/* Don't modify URLs of the format "#mark" */
if (bash && bash - url->s->val == 0) {
- smart_str_append(dest, url);
+ smart_str_append_smart_str(dest, url);
return;
}
if (bash)
smart_str_appendl(dest, url->s->val, bash - url->s->val);
else
- smart_str_append(dest, url);
+ smart_str_append_smart_str(dest, url);
smart_str_appends(dest, sep);
- smart_str_append(dest, url_app);
+ smart_str_append_smart_str(dest, url_app);
if (bash)
smart_str_appendl(dest, bash, q - bash);
@@ -166,7 +166,7 @@ static inline void tag_arg(url_adapt_state_ex_t *ctx, char quotes, char type TSR
if (f) {
append_modified_url(&ctx->val, &ctx->result, &ctx->url_app, PG(arg_separator).output);
} else {
- smart_str_append(&ctx->result, &ctx->val);
+ smart_str_append_smart_str(&ctx->result, &ctx->val);
}
if (quotes)
smart_str_appendc(&ctx->result, type);
@@ -240,7 +240,7 @@ static void handle_form(STD_PARA)
}
if (doit)
- smart_str_append(&ctx->result, &ctx->form_app);
+ smart_str_append_smart_str(&ctx->result, &ctx->form_app);
}
}
@@ -410,7 +410,7 @@ static char *url_adapt_ext(const char *src, size_t srclen, size_t *newlen, zend_
}
smart_str_0(&ctx->result);
if (do_flush) {
- smart_str_appendl(&ctx->result, ctx->buf.s->val, ctx->buf.s->len);
+ smart_str_append(&ctx->result, ctx->buf.s);
*newlen += ctx->buf.s->len;
smart_str_free(&ctx->buf);
smart_str_free(&ctx->val);
@@ -459,7 +459,7 @@ static void php_url_scanner_output_handler(char *output, uint output_len, char *
} else if (BG(url_adapt_state_ex).url_app.s->len == 0) {
url_adapt_state_ex_t *ctx = &BG(url_adapt_state_ex);
if (ctx->buf.s && ctx->buf.s->len) {
- smart_str_appendl(&ctx->result, ctx->buf.s->val, ctx->buf.s->len);
+ smart_str_append(&ctx->result, ctx->buf.s);
smart_str_appendl(&ctx->result, output, output_len);
*handled_output = estrndup(ctx->result.s->val, ctx->result.s->len);
@@ -500,12 +500,12 @@ PHPAPI int php_url_scanner_add_var(char *name, int name_len, char *value, int va
smart_str_appendl(&BG(url_adapt_state_ex).url_app, name, name_len);
smart_str_appendc(&BG(url_adapt_state_ex).url_app, '=');
- smart_str_append(&BG(url_adapt_state_ex).url_app, &val);
+ smart_str_append_smart_str(&BG(url_adapt_state_ex).url_app, &val);
smart_str_appends(&BG(url_adapt_state_ex).form_app, "<input type=\"hidden\" name=\"");
smart_str_appendl(&BG(url_adapt_state_ex).form_app, name, name_len);
smart_str_appends(&BG(url_adapt_state_ex).form_app, "\" value=\"");
- smart_str_append(&BG(url_adapt_state_ex).form_app, &val);
+ smart_str_append_smart_str(&BG(url_adapt_state_ex).form_app, &val);
smart_str_appends(&BG(url_adapt_state_ex).form_app, "\" />");
if (urlencode) {
diff --git a/ext/standard/user_filters.c b/ext/standard/user_filters.c
index ea73662db6..19e8e454df 100644
--- a/ext/standard/user_filters.c
+++ b/ext/standard/user_filters.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/uuencode.c b/ext/standard/uuencode.c
index 40ab379a30..6582e7de65 100644
--- a/ext/standard/uuencode.c
+++ b/ext/standard/uuencode.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/standard/var.c b/ext/standard/var.c
index f005258fcb..53fd54c647 100644
--- a/ext/standard/var.c
+++ b/ext/standard/var.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -28,7 +28,7 @@
#include "php.h"
#include "php_string.h"
#include "php_var.h"
-#include "php_smart_str.h"
+#include "zend_smart_str.h"
#include "basic_functions.h"
#include "php_incomplete_class.h"
@@ -74,7 +74,7 @@ static void php_object_property_dump(zval *zv, zend_ulong index, zend_string *ke
if (key == NULL) { /* numeric key */
php_printf("%*c[" ZEND_LONG_FMT "]=>\n", level + 1, ' ', index);
} else { /* string key */
- int unmangle = zend_unmangle_property_name(key->val, key->len, &class_name, &prop_name);
+ int unmangle = zend_unmangle_property_name(key, &class_name, &prop_name);
php_printf("%*c[", level + 1, ' ');
if (class_name && unmangle == SUCCESS) {
@@ -247,7 +247,7 @@ static void zval_object_property_dump(zval *zv, zend_ulong index, zend_string *k
if (key == NULL) { /* numeric key */
php_printf("%*c[" ZEND_LONG_FMT "]=>\n", level + 1, ' ', index);
} else { /* string key */
- zend_unmangle_property_name(key->val, key->len, &class_name, &prop_name);
+ zend_unmangle_property_name(key, &class_name, &prop_name);
php_printf("%*c[", level + 1, ' ');
if (class_name) {
@@ -299,7 +299,7 @@ again:
case IS_STRING:
php_printf("%sstring(%d) \"", COMMON, Z_STRLEN_P(struc));
PHPWRITE(Z_STRVAL_P(struc), Z_STRLEN_P(struc));
- php_printf("\" refcount(%u)\n", IS_INTERNED(Z_STR_P(struc)) ? 1 : Z_REFCOUNT_P(struc));
+ php_printf("\" refcount(%u)\n", Z_REFCOUNTED_P(struc) ? Z_REFCOUNT_P(struc) : 1);
break;
case IS_ARRAY:
myht = Z_ARRVAL_P(struc);
@@ -413,7 +413,7 @@ static void php_array_element_export(zval *zv, zend_ulong index, zend_string *ke
buffer_append_spaces(buf, level + 1);
smart_str_appendc(buf, '\'');
- smart_str_appendl(buf, tmp_str->val, tmp_str->len);
+ smart_str_append(buf, tmp_str);
smart_str_appendl(buf, "' => ", 5);
zend_string_free(ckey);
@@ -430,16 +430,15 @@ static void php_object_element_export(zval *zv, zend_ulong index, zend_string *k
{
buffer_append_spaces(buf, level + 2);
if (key != NULL) {
- const char *class_name; /* ignored, but must be passed to unmangle */
- const char *pname;
+ const char *class_name, *prop_name;
+ size_t prop_name_len;
zend_string *pname_esc;
- zend_unmangle_property_name(key->val, key->len,
- &class_name, &pname);
- pname_esc = php_addcslashes(pname, strlen(pname), 0, "'\\", 2 TSRMLS_CC);
+ zend_unmangle_property_name_ex(key, &class_name, &prop_name, &prop_name_len);
+ pname_esc = php_addcslashes(prop_name, prop_name_len, 0, "'\\", 2 TSRMLS_CC);
smart_str_appendc(buf, '\'');
- smart_str_appendl(buf, pname_esc->val, pname_esc->len);
+ smart_str_append(buf, pname_esc);
smart_str_appendc(buf, '\'');
zend_string_release(pname_esc);
} else {
@@ -487,7 +486,7 @@ again:
ztmp2 = php_str_to_str_ex(ztmp->val, ztmp->len, "\0", 1, "' . \"\\0\" . '", 12, 0, NULL);
smart_str_appendc(buf, '\'');
- smart_str_appendl(buf, ztmp2->val, ztmp2->len);
+ smart_str_append(buf, ztmp2);
smart_str_appendc(buf, '\'');
zend_string_free(ztmp);
@@ -536,7 +535,7 @@ again:
}
class_name = Z_OBJ_HANDLER_P(struc, get_class_name)(Z_OBJ_P(struc), 0 TSRMLS_CC);
- smart_str_appendl(buf, class_name->val, class_name->len);
+ smart_str_append(buf, class_name);
smart_str_appendl(buf, "::__set_state(array(\n", 21);
zend_string_release(class_name);
@@ -599,54 +598,51 @@ PHP_FUNCTION(var_export)
}
/* }}} */
-static void php_var_serialize_intern(smart_str *buf, zval *struc, HashTable *var_hash TSRMLS_DC);
+static void php_var_serialize_intern(smart_str *buf, zval *struc, php_serialize_data_t var_hash TSRMLS_DC);
-static inline int php_add_var_hash(HashTable *var_hash, zval *var_ptr, zval *var_old TSRMLS_DC) /* {{{ */
+static inline uint32_t php_add_var_hash(php_serialize_data_t data, zval *var TSRMLS_DC) /* {{{ */
{
- zval var_no, *zv;
- char id[32], *p;
- register int len;
- zval *var = var_ptr;
+ zval *zv;
+ zend_ulong key;
+ zend_bool is_ref = Z_ISREF_P(var);
- if (Z_ISREF_P(var)) {
- var = Z_REFVAL_P(var);
+ data->n += 1;
+
+ if (!is_ref && Z_TYPE_P(var) != IS_OBJECT) {
+ return 0;
}
- if ((Z_TYPE_P(var) == IS_OBJECT) && Z_OBJ_HT_P(var)->get_class_entry) {
- p = smart_str_print_long(id + sizeof(id) - 1,
- (zend_long) Z_OBJ_P(var));
- *(--p) = 'O';
- len = id + sizeof(id) - 1 - p;
- } else if (var_ptr != var) {
- p = smart_str_print_long(id + sizeof(id) - 1,
- (zend_long) Z_REF_P(var_ptr));
- *(--p) = 'R';
- len = id + sizeof(id) - 1 - p;
- } else {
- p = smart_str_print_long(id + sizeof(id) - 1, (zend_long) var);
- len = id + sizeof(id) - 1 - p;
+
+ /* References to objects are treated as if the reference didn't exist */
+ if (is_ref && Z_TYPE_P(Z_REFVAL_P(var)) == IS_OBJECT) {
+ var = Z_REFVAL_P(var);
}
- if ((zv = zend_hash_str_find(var_hash, p, len)) != NULL) {
- ZVAL_COPY_VALUE(var_old, zv);
- if (var == var_ptr) {
- /* we still need to bump up the counter, since non-refs will
- * be counted separately by unserializer */
- ZVAL_LONG(&var_no, -1);
- zend_hash_next_index_insert(var_hash, &var_no);
+ /* Index for the variable is stored using the numeric value of the pointer to
+ * the zend_refcounted struct */
+ key = (zend_ulong) (zend_uintptr_t) Z_COUNTED_P(var);
+ zv = zend_hash_index_find(&data->ht, key);
+
+ if (zv) {
+ /* References are only counted once, undo the data->n increment above */
+ if (is_ref) {
+ data->n -= 1;
}
-#if 0
- fprintf(stderr, "- had var (%d): %lu\n", Z_TYPE_P(var), **(zend_ulong**)var_old);
-#endif
- return FAILURE;
- }
- /* +1 because otherwise hash will think we are trying to store NULL pointer */
- ZVAL_LONG(&var_no, zend_hash_num_elements(var_hash) + 1);
- zend_hash_str_add(var_hash, p, len, &var_no);
-#if 0
- fprintf(stderr, "+ add var (%d): %lu\n", Z_TYPE_P(var), Z_LVAL(var_no));
-#endif
- return SUCCESS;
+ return Z_LVAL_P(zv);
+ } else {
+ zval zv_n;
+ ZVAL_LONG(&zv_n, data->n);
+ zend_hash_index_add_new(&data->ht, key, &zv_n);
+
+ /* Additionally to the index, we also store the variable, to ensure that it is
+ * not destroyed during serialization and its pointer reused. The variable is
+ * stored at the numeric value of the pointer + 1, which cannot be the location
+ * of another zend_refcounted structure. */
+ zend_hash_index_add_new(&data->ht, key + 1, var);
+ Z_ADDREF_P(var);
+
+ return 0;
+ }
}
/* }}} */
@@ -658,10 +654,10 @@ static inline void php_var_serialize_long(smart_str *buf, zend_long val) /* {{{
}
/* }}} */
-static inline void php_var_serialize_string(smart_str *buf, char *str, int len) /* {{{ */
+static inline void php_var_serialize_string(smart_str *buf, char *str, size_t len) /* {{{ */
{
smart_str_appendl(buf, "s:", 2);
- smart_str_append_long(buf, len);
+ smart_str_append_unsigned(buf, len);
smart_str_appendl(buf, ":\"", 2);
smart_str_appendl(buf, str, len);
smart_str_appendl(buf, "\";", 2);
@@ -674,18 +670,18 @@ static inline zend_bool php_var_serialize_class_name(smart_str *buf, zval *struc
PHP_SET_CLASS_ATTRIBUTES(struc);
smart_str_appendl(buf, "O:", 2);
- smart_str_append_long(buf, (int)class_name->len);
+ smart_str_append_unsigned(buf, class_name->len);
smart_str_appendl(buf, ":\"", 2);
- smart_str_appendl(buf, class_name->val, class_name->len);
+ smart_str_append(buf, class_name);
smart_str_appendl(buf, "\":", 2);
PHP_CLEANUP_CLASS_ATTRIBUTES();
return incomplete_class;
}
/* }}} */
-static void php_var_serialize_class(smart_str *buf, zval *struc, zval *retval_ptr, HashTable *var_hash TSRMLS_DC) /* {{{ */
+static void php_var_serialize_class(smart_str *buf, zval *struc, zval *retval_ptr, php_serialize_data_t var_hash TSRMLS_DC) /* {{{ */
{
- int count;
+ uint32_t count;
zend_bool incomplete_class;
incomplete_class = php_var_serialize_class_name(buf, struc TSRMLS_CC);
@@ -695,7 +691,7 @@ static void php_var_serialize_class(smart_str *buf, zval *struc, zval *retval_pt
if (incomplete_class) {
--count;
}
- smart_str_append_long(buf, count);
+ smart_str_append_unsigned(buf, count);
smart_str_appendl(buf, ":{", 2);
if (count > 0) {
@@ -781,28 +777,24 @@ static void php_var_serialize_class(smart_str *buf, zval *struc, zval *retval_pt
}
/* }}} */
-static void php_var_serialize_intern(smart_str *buf, zval *struc, HashTable *var_hash TSRMLS_DC) /* {{{ */
+static void php_var_serialize_intern(smart_str *buf, zval *struc, php_serialize_data_t var_hash TSRMLS_DC) /* {{{ */
{
- int i;
- zval var_already;
+ uint32_t var_already;
HashTable *myht;
if (EG(exception)) {
return;
}
- ZVAL_UNDEF(&var_already);
-
- if (var_hash &&
- php_add_var_hash(var_hash, struc, &var_already TSRMLS_CC) == FAILURE) {
+ if (var_hash && (var_already = php_add_var_hash(var_hash, struc TSRMLS_CC))) {
if (Z_ISREF_P(struc)) {
smart_str_appendl(buf, "R:", 2);
- smart_str_append_long(buf, Z_LVAL(var_already));
+ smart_str_append_long(buf, var_already);
smart_str_appendc(buf, ';');
return;
} else if (Z_TYPE_P(struc) == IS_OBJECT) {
smart_str_appendl(buf, "r:", 2);
- smart_str_append_long(buf, Z_LVAL(var_already));
+ smart_str_append_long(buf, var_already);
smart_str_appendc(buf, ';');
return;
}
@@ -855,18 +847,18 @@ again:
if (ce && ce->serialize != NULL) {
/* has custom handler */
unsigned char *serialized_data = NULL;
- uint32_t serialized_length;
+ size_t serialized_length;
if (ce->serialize(struc, &serialized_data, &serialized_length, (zend_serialize_data *)var_hash TSRMLS_CC) == SUCCESS) {
smart_str_appendl(buf, "C:", 2);
- smart_str_append_long(buf, (int)Z_OBJCE_P(struc)->name->len);
+ smart_str_append_unsigned(buf, Z_OBJCE_P(struc)->name->len);
smart_str_appendl(buf, ":\"", 2);
- smart_str_appendl(buf, Z_OBJCE_P(struc)->name->val, Z_OBJCE_P(struc)->name->len);
+ smart_str_append(buf, Z_OBJCE_P(struc)->name);
smart_str_appendl(buf, "\":", 2);
- smart_str_append_long(buf, (int)serialized_length);
+ smart_str_append_unsigned(buf, serialized_length);
smart_str_appendl(buf, ":{", 2);
- smart_str_appendl(buf, serialized_data, serialized_length);
+ smart_str_appendl(buf, (char *) serialized_data, serialized_length);
smart_str_appendc(buf, '}');
} else {
smart_str_appendl(buf, "N;", 2);
@@ -909,6 +901,7 @@ again:
/* fall-through */
}
case IS_ARRAY: {
+ uint32_t i;
zend_bool incomplete_class = 0;
if (Z_TYPE_P(struc) == IS_ARRAY) {
smart_str_appendl(buf, "a:", 2);
@@ -923,7 +916,7 @@ again:
if (i > 0 && incomplete_class) {
--i;
}
- smart_str_append_long(buf, i);
+ smart_str_append_unsigned(buf, i);
smart_str_appendl(buf, ":{", 2);
if (i > 0) {
zend_string *key;
@@ -972,9 +965,9 @@ again:
}
/* }}} */
-PHPAPI void php_var_serialize(smart_str *buf, zval *struc, php_serialize_data_t *var_hash TSRMLS_DC) /* {{{ */
+PHPAPI void php_var_serialize(smart_str *buf, zval *struc, php_serialize_data_t *data TSRMLS_DC) /* {{{ */
{
- php_var_serialize_intern(buf, struc, *var_hash TSRMLS_CC);
+ php_var_serialize_intern(buf, struc, *data TSRMLS_CC);
smart_str_0(buf);
}
/* }}} */
diff --git a/ext/standard/var_unserializer.c b/ext/standard/var_unserializer.c
index 7e6789daaa..c94f3eec58 100644
--- a/ext/standard/var_unserializer.c
+++ b/ext/standard/var_unserializer.c
@@ -2,7 +2,7 @@
#line 1 "ext/standard/var_unserializer.re"
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -700,7 +700,7 @@ yy20:
/* Call unserialize callback */
ZVAL_STRING(&user_func, PG(unserialize_callback_func));
- ZVAL_STR(&args[0], zend_string_copy(class_name));
+ ZVAL_STR_COPY(&args[0], class_name);
BG(serialize_lock)++;
if (call_user_function_ex(CG(function_table), NULL, &user_func, &retval, 1, args, 0, NULL TSRMLS_CC) != SUCCESS) {
BG(serialize_lock)--;
diff --git a/ext/standard/var_unserializer.re b/ext/standard/var_unserializer.re
index 39161353f8..a11f556f7e 100644
--- a/ext/standard/var_unserializer.re
+++ b/ext/standard/var_unserializer.re
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -755,7 +755,7 @@ object ":" uiv ":" ["] {
/* Call unserialize callback */
ZVAL_STRING(&user_func, PG(unserialize_callback_func));
- ZVAL_STR(&args[0], zend_string_copy(class_name));
+ ZVAL_STR_COPY(&args[0], class_name);
BG(serialize_lock)++;
if (call_user_function_ex(CG(function_table), NULL, &user_func, &retval, 1, args, 0, NULL TSRMLS_CC) != SUCCESS) {
BG(serialize_lock)--;
diff --git a/ext/standard/versioning.c b/ext/standard/versioning.c
index e6f5e480ae..ffdd5abf0d 100644
--- a/ext/standard/versioning.c
+++ b/ext/standard/versioning.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/sybase_ct/php_sybase_ct.c b/ext/sybase_ct/php_sybase_ct.c
index 12afe6f278..c079ff383d 100644
--- a/ext/sybase_ct/php_sybase_ct.c
+++ b/ext/sybase_ct/php_sybase_ct.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/sybase_ct/php_sybase_ct.h b/ext/sybase_ct/php_sybase_ct.h
index 8e4993e0ed..476e620588 100644
--- a/ext/sybase_ct/php_sybase_ct.h
+++ b/ext/sybase_ct/php_sybase_ct.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/sybase_ct/sybase_ct.dsp b/ext/sybase_ct/sybase_ct.dsp
deleted file mode 100644
index be2f890bab..0000000000
--- a/ext/sybase_ct/sybase_ct.dsp
+++ /dev/null
@@ -1,114 +0,0 @@
-# Microsoft Developer Studio Project File - Name="sybase_ct" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=sybase_ct - Win32 Release_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "sybase_ct.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "sybase_ct.mak" CFG="sybase_ct - Win32 Release_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "sybase_ct - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "sybase_ct - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "sybase_ct - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\..\Zend" /I "..\..\..\TSRM" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "SYBASE_CT_EXPORTS" /D "COMPILE_DL_SYBASE_CT" /D ZTS=1 /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /D "WIN32" /D "SYBASE_CT_EXPORTS" /D "COMPILE_DL_SYBASE_CT" /D HAVE_SYBASE_CT=1 /D ZTS=1 /D ZEND_DEBUG=0 /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ZEND_WIN32" /D "PHP_WIN32" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib /nologo /dll /machine:I386
-# ADD LINK32 php5ts.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib libct.lib libcs.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_sybase_ct.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-# SUBTRACT LINK32 /pdb:none
-
-!ELSEIF "$(CFG)" == "sybase_ct - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "SYBASE_CT_EXPORTS" /D "COMPILE_DL_SYBASE_CT" /D ZTS=1 /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "SYBASE_CT_EXPORTS" /D "COMPILE_DL_SYBASE_CT" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_SYBASE_CT=1 /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts_debug.lib /nologo /dll /machine:I386
-# ADD LINK32 php5ts_debug.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Debug_TS/php_sybase_ct.dll" /libpath:"..\..\Debug_TS"
-
-!ENDIF
-
-# Begin Target
-
-# Name "sybase_ct - Win32 Release_TS"
-# Name "sybase_ct - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\php_sybase_ct.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_sybase_ct.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# End Target
-# End Project
diff --git a/ext/sysvmsg/php_sysvmsg.h b/ext/sysvmsg/php_sysvmsg.h
index 53ac7fc0ee..139d37fe38 100644
--- a/ext/sysvmsg/php_sysvmsg.h
+++ b/ext/sysvmsg/php_sysvmsg.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/sysvmsg/sysvmsg.c b/ext/sysvmsg/sysvmsg.c
index d6b8638ddd..d158366ea5 100644
--- a/ext/sysvmsg/sysvmsg.c
+++ b/ext/sysvmsg/sysvmsg.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -27,7 +27,7 @@
#include "ext/standard/info.h"
#include "php_sysvmsg.h"
#include "ext/standard/php_var.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
/* In order to detect MSG_EXCEPT use at run time; we have no way
* of knowing what the bit definitions are, so we can't just define
diff --git a/ext/sysvsem/php_sysvsem.h b/ext/sysvsem/php_sysvsem.h
index 964c3d3de4..8c2c2e5d3b 100644
--- a/ext/sysvsem/php_sysvsem.h
+++ b/ext/sysvsem/php_sysvsem.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/sysvsem/sysvsem.c b/ext/sysvsem/sysvsem.c
index 6f7948519e..299c725c6b 100644
--- a/ext/sysvsem/sysvsem.c
+++ b/ext/sysvsem/sysvsem.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -66,6 +66,7 @@ ZEND_END_ARG_INFO()
ZEND_BEGIN_ARG_INFO_EX(arginfo_sem_acquire, 0, 0, 1)
ZEND_ARG_INFO(0, sem_identifier)
+ ZEND_ARG_INFO(0, nowait)
ZEND_END_ARG_INFO()
ZEND_BEGIN_ARG_INFO_EX(arginfo_sem_release, 0, 0, 1)
@@ -299,11 +300,18 @@ PHP_FUNCTION(sem_get)
static void php_sysvsem_semop(INTERNAL_FUNCTION_PARAMETERS, int acquire)
{
zval *arg_id;
+ zend_bool nowait = 0;
sysvsem_sem *sem_ptr;
struct sembuf sop;
- if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "r", &arg_id) == FAILURE) {
- return;
+ if (acquire) {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "r|b", &arg_id, &nowait) == FAILURE) {
+ return;
+ }
+ } else {
+ if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "r", &arg_id) == FAILURE) {
+ return;
+ }
}
ZEND_FETCH_RESOURCE(sem_ptr, sysvsem_sem *, arg_id, -1, "SysV semaphore", php_sysvsem_module.le_sem);
@@ -315,11 +323,13 @@ static void php_sysvsem_semop(INTERNAL_FUNCTION_PARAMETERS, int acquire)
sop.sem_num = SYSVSEM_SEM;
sop.sem_op = acquire ? -1 : 1;
- sop.sem_flg = SEM_UNDO;
+ sop.sem_flg = SEM_UNDO | (nowait ? IPC_NOWAIT : 0);
while (semop(sem_ptr->semid, &sop, 1) == -1) {
if (errno != EINTR) {
- php_error_docref(NULL TSRMLS_CC, E_WARNING, "failed to %s key 0x%x: %s", acquire ? "acquire" : "release", sem_ptr->key, strerror(errno));
+ if (errno != EAGAIN) {
+ php_error_docref(NULL TSRMLS_CC, E_WARNING, "failed to %s key 0x%x: %s", acquire ? "acquire" : "release", sem_ptr->key, strerror(errno));
+ }
RETURN_FALSE;
}
}
diff --git a/ext/sysvsem/tests/nowait.phpt b/ext/sysvsem/tests/nowait.phpt
new file mode 100644
index 0000000000..0a6fdf4a50
--- /dev/null
+++ b/ext/sysvsem/tests/nowait.phpt
@@ -0,0 +1,103 @@
+--TEST--
+sem_acquire with nowait
+--SKIPIF--
+<?php // vim600: ts=4 sw=4 syn=php fdm=marker
+if(!extension_loaded('sysvsem') || !extension_loaded('pcntl')) {
+ die("skip sysvsem and pcntl required");
+}
+?>
+--FILE--
+<?php
+$SEMKEY = ftok(__FILE__, 'P'); // Semaphore key
+
+$pid = pcntl_fork();
+
+if ($pid) {
+ echo "Parent.\n";
+
+ pcntl_signal(SIGCHLD, SIG_IGN);
+
+ // Get semaphore
+ $sem_id = sem_get($SEMKEY, 1);
+ if ($sem_id === FALSE) {
+ echo "P: fail to get semaphore";
+ exit;
+ }
+ echo "P: got semaphore $sem_id.\n";
+
+ register_shutdown_function(function () use ($sem_id) {
+ echo "P: cleanup.\n";
+ sem_remove($sem_id);
+ });
+
+ // Acquire semaphore
+ if (! sem_acquire($sem_id)) {
+ echo "P: fail to acquire semaphore $sem_id.\n";
+ sem_remove($sem_id);
+ exit;
+ }
+ echo "P: success acquire semaphore $sem_id.\n";
+
+ usleep(20000);
+
+ echo "P: releases.\n";
+ sem_release($sem_id);
+
+ usleep(5000);
+
+ // Acquire semaphore
+ if (! sem_acquire($sem_id)) {
+ echo "P: fail to acquire semaphore $sem_id.\n";
+ sem_remove($sem_id);
+ exit;
+ }
+ echo "P: success acquire semaphore $sem_id.\n";
+
+ $status = null;
+ pcntl_waitpid($pid, $status);
+
+} else {
+ usleep(10000);
+ echo "Child.\n";
+
+ // Get semaphore
+ $sem_id = sem_get($SEMKEY, 1);
+ if ($sem_id === FALSE) {
+ echo "C: fail to get semaphore";
+ exit;
+ }
+ echo "C: got semaphore $sem_id.\n";
+
+ // Acquire semaphore
+ if (! sem_acquire($sem_id)) {
+ echo "C: fail to acquire semaphore $sem_id.\n";
+ exit;
+ }
+ echo "C: success acquire semaphore $sem_id.\n";
+
+ echo "C: releases.\n";
+ sem_release($sem_id);
+
+ usleep(10000);
+
+ // Acquire semaphore
+ if (! sem_acquire($sem_id, true)) {
+ echo "C: fail to acquire semaphore $sem_id.\n";
+ exit;
+ }
+ echo "C: success acquire semaphore $sem_id.\n";
+}
+
+?>
+--EXPECTF--
+Parent.
+P: got semaphore Resource id #%i.
+P: success acquire semaphore Resource id #%i.
+Child.
+C: got semaphore Resource id #%i.
+P: releases.
+C: success acquire semaphore Resource id #%i.
+C: releases.
+P: success acquire semaphore Resource id #%i.
+C: fail to acquire semaphore Resource id #%i.
+P: cleanup.
diff --git a/ext/sysvsem/tests/sysv.phpt b/ext/sysvsem/tests/sysv.phpt
index 6f52f3bd7e..ccfcf03d32 100644
--- a/ext/sysvsem/tests/sysv.phpt
+++ b/ext/sysvsem/tests/sysv.phpt
@@ -9,8 +9,8 @@ if(!extension_loaded('sysvsem') || !extension_loaded('sysvshm')) {
--FILE--
<?php
$MEMSIZE = 512; // size of shared memory to allocate
-$SEMKEY = 1; // Semaphore key
-$SHMKEY = 2; // Shared memory key
+$SEMKEY = ftok(__FILE__, 'P'); // Semaphore key
+$SHMKEY = ftok(__FILE__, 'Q'); // Shared memory key
echo "Start.\n";
// Get semaphore
diff --git a/ext/sysvshm/php_sysvshm.h b/ext/sysvshm/php_sysvshm.h
index 0d174002b1..9dd9272dfe 100644
--- a/ext/sysvshm/php_sysvshm.h
+++ b/ext/sysvshm/php_sysvshm.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/sysvshm/sysvshm.c b/ext/sysvshm/sysvshm.c
index 2a0d0e8246..c87be09e4f 100644
--- a/ext/sysvshm/sysvshm.c
+++ b/ext/sysvshm/sysvshm.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -36,7 +36,7 @@
#include "php_sysvshm.h"
#include "ext/standard/php_var.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#include "php_ini.h"
/* {{{ arginfo */
diff --git a/ext/tidy/examples/cleanhtml.php b/ext/tidy/examples/cleanhtml.php
index 2644210cbf..b47384b810 100644
--- a/ext/tidy/examples/cleanhtml.php
+++ b/ext/tidy/examples/cleanhtml.php
@@ -34,7 +34,3 @@
echo tidy_get_output();
?>
-
-
-
- \ No newline at end of file
diff --git a/ext/tidy/examples/cleanhtml5.php b/ext/tidy/examples/cleanhtml5.php
index 2ce683acad..c5a1fcd338 100644
--- a/ext/tidy/examples/cleanhtml5.php
+++ b/ext/tidy/examples/cleanhtml5.php
@@ -33,7 +33,3 @@
echo $tidy;
?>
-
-
-
-
diff --git a/ext/tidy/php_tidy.h b/ext/tidy/php_tidy.h
index efeba3baa9..cd78f37a17 100644
--- a/ext/tidy/php_tidy.h
+++ b/ext/tidy/php_tidy.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/tidy/tidy.c b/ext/tidy/tidy.c
index 7fdf6087b4..63ccf52370 100644
--- a/ext/tidy/tidy.c
+++ b/ext/tidy/tidy.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/tidy/tidy.dsp b/ext/tidy/tidy.dsp
deleted file mode 100755
index fe44fa7a51..0000000000
--- a/ext/tidy/tidy.dsp
+++ /dev/null
@@ -1,108 +0,0 @@
-# Microsoft Developer Studio Project File - Name="tidy" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=tidy - Win32 Debug_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "tidy.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "tidy.mak" CFG="tidy - Win32 Debug_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "tidy - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "tidy - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "tidy - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MD /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "TIDY_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\..\php_build\include" /I "..\..\..\php_build\include\libtidy" /D ZEND_DEBUG=0 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "COMPILE_DL_TIDY" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D "PHP_TIDY_EXPORTS" /D "HAVE_ZLIB" /FR /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "NDEBUG"
-# ADD RSC /l 0x407 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 php5ts.lib libtidy.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_tidy.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline" /libpath:"..\..\..\php_build\release"
-
-!ELSEIF "$(CFG)" == "tidy - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "TIDY_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\..\php_build\include" /I "..\..\..\php_build\include\libtidy" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "COMPILE_DL_TIDY" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D "PHP_TIDY_EXPORTS" /D "HAVE_ZLIB" /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "_DEBUG"
-# ADD RSC /l 0x407 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 php5ts_debug.lib libtidy.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_tidy.dll" /pdbtype:sept /libpath:"..\..\Debug_TS" /libpath:"..\..\..\php_build\release"
-
-!ENDIF
-
-# Begin Target
-
-# Name "tidy - Win32 Release_TS"
-# Name "tidy - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\tidy.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_tidy.h
-# End Source File
-# End Group
-# End Target
-# End Project
diff --git a/ext/tokenizer/php_tokenizer.h b/ext/tokenizer/php_tokenizer.h
index 1b5490d257..c6946c7078 100644
--- a/ext/tokenizer/php_tokenizer.h
+++ b/ext/tokenizer/php_tokenizer.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/tokenizer/tokenizer.c b/ext/tokenizer/tokenizer.c
index 1847b0537d..26e05c2be3 100644
--- a/ext/tokenizer/tokenizer.c
+++ b/ext/tokenizer/tokenizer.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -185,7 +185,7 @@ PHP_FUNCTION(token_get_all)
return;
}
- ZVAL_STR(&source_zval, zend_string_copy(source));
+ ZVAL_STR_COPY(&source_zval, source);
zend_save_lexical_state(&original_lex_state TSRMLS_CC);
if (zend_prepare_string_for_scanning(&source_zval, "" TSRMLS_CC) == FAILURE) {
diff --git a/ext/tokenizer/tokenizer.dsp b/ext/tokenizer/tokenizer.dsp
deleted file mode 100644
index 9844574a8a..0000000000
--- a/ext/tokenizer/tokenizer.dsp
+++ /dev/null
@@ -1,108 +0,0 @@
-# Microsoft Developer Studio Project File - Name="tokenizer" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=tokenizer - Win32 Debug_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "tokenizer.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "tokenizer.mak" CFG="tokenizer - Win32 Debug_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "tokenizer - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "tokenizer - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "tokenizer - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MD /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "TOKENIZER_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /D ZEND_DEBUG=0 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "PHP_EXPORTS" /D "COMPILE_DL_TOKENIZER" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_TOKENIZER=1 /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "NDEBUG"
-# ADD RSC /l 0x407 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 php5ts.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_tokenizer.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline"
-
-!ELSEIF "$(CFG)" == "tokenizer - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "TOKENIZER_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "PHP_EXPORTS" /D "COMPILE_DL_TOKENIZER" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_TOKENIZER=1 /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x407 /d "_DEBUG"
-# ADD RSC /l 0x407 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 php5ts_debug.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_tokenizer.dll" /pdbtype:sept /libpath:"..\..\Debug_TS"
-
-!ENDIF
-
-# Begin Target
-
-# Name "tokenizer - Win32 Release_TS"
-# Name "tokenizer - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\tokenizer.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_tokenizer.h
-# End Source File
-# End Group
-# End Target
-# End Project
diff --git a/ext/tokenizer/tokenizer_data.c b/ext/tokenizer/tokenizer_data.c
index beb9ea8e5b..49dec7c150 100644
--- a/ext/tokenizer/tokenizer_data.c
+++ b/ext/tokenizer/tokenizer_data.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/tokenizer/tokenizer_data_gen.sh b/ext/tokenizer/tokenizer_data_gen.sh
index 1ed76e3617..a00d341528 100755
--- a/ext/tokenizer/tokenizer_data_gen.sh
+++ b/ext/tokenizer/tokenizer_data_gen.sh
@@ -14,7 +14,7 @@ fi
echo '/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/wddx/php_wddx.h b/ext/wddx/php_wddx.h
index 7e823f7c8f..3809c0a3e1 100644
--- a/ext/wddx/php_wddx.h
+++ b/ext/wddx/php_wddx.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/wddx/php_wddx_api.h b/ext/wddx/php_wddx_api.h
index d20f007345..5c47109ee3 100644
--- a/ext/wddx/php_wddx_api.h
+++ b/ext/wddx/php_wddx_api.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -21,7 +21,7 @@
#ifndef PHP_WDDX_API_H
#define PHP_WDDX_API_H
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str_public.h"
#define WDDX_ARRAY_S "<array length='%d'>"
#define WDDX_ARRAY_E "</array>"
diff --git a/ext/wddx/wddx.c b/ext/wddx/wddx.c
index 931ea81c4e..705babd885 100644
--- a/ext/wddx/wddx.c
+++ b/ext/wddx/wddx.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -35,7 +35,7 @@
#include "ext/standard/php_incomplete_class.h"
#include "ext/standard/base64.h"
#include "ext/standard/info.h"
-#include "ext/standard/php_smart_str.h"
+#include "zend_smart_str.h"
#include "ext/standard/html.h"
#include "ext/standard/php_string.h"
#include "ext/date/php_date.h"
@@ -289,7 +289,7 @@ PS_SERIALIZER_DECODE_FUNC(wddx)
zval retval;
zval *ent;
zend_string *key;
- ulong idx;
+ zend_ulong idx;
int ret;
if (vallen == 0) {
@@ -442,7 +442,7 @@ static void php_wddx_serialize_object(wddx_packet *packet, zval *obj)
zval *ent, fname, *varname;
zval retval;
zend_string *key;
- ulong idx;
+ zend_ulong idx;
char tmp_buf[WDDX_BUF_LEN];
HashTable *objhash, *sleephash;
TSRMLS_FETCH();
@@ -505,10 +505,11 @@ static void php_wddx_serialize_object(wddx_packet *packet, zval *obj)
}
if (key) {
const char *class_name, *prop_name;
+ size_t prop_name_len;
zend_string *tmp;
- zend_unmangle_property_name(key->val, key->len, &class_name, &prop_name);
- tmp = zend_string_init(prop_name, strlen(prop_name), 0);
+ zend_unmangle_property_name_ex(key, &class_name, &prop_name, &prop_name_len);
+ tmp = zend_string_init(prop_name, prop_name_len, 0);
php_wddx_serialize_var(packet, ent, tmp TSRMLS_CC);
zend_string_release(tmp);
} else {
@@ -532,10 +533,10 @@ static void php_wddx_serialize_array(wddx_packet *packet, zval *arr)
zval *ent;
zend_string *key;
int is_struct = 0;
- ulong idx;
+ zend_ulong idx;
HashTable *target_hash;
char tmp_buf[WDDX_BUF_LEN];
- ulong ind = 0;
+ zend_ulong ind = 0;
TSRMLS_FETCH();
target_hash = HASH_OF(arr);
diff --git a/ext/xml/compat.c b/ext/xml/compat.c
index 81f5cb9667..c046e150da 100644
--- a/ext/xml/compat.c
+++ b/ext/xml/compat.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/xml/expat_compat.h b/ext/xml/expat_compat.h
index dab9812122..54673f9ad0 100644
--- a/ext/xml/expat_compat.h
+++ b/ext/xml/expat_compat.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/xml/php_xml.h b/ext/xml/php_xml.h
index 0195bb5836..cdb08f812e 100644
--- a/ext/xml/php_xml.h
+++ b/ext/xml/php_xml.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -134,8 +134,8 @@ PHP_FUNCTION(utf8_decode);
PHP_FUNCTION(xml_parse_into_struct);
PHPAPI char *_xml_zval_strdup(zval *);
-PHPAPI zend_string *xml_utf8_decode(const XML_Char *, int, const XML_Char *);
-PHPAPI zend_string *xml_utf8_encode(const char *, int, const XML_Char *);
+PHPAPI zend_string *xml_utf8_decode(const XML_Char *, size_t, const XML_Char *);
+PHPAPI zend_string *xml_utf8_encode(const char *, size_t, const XML_Char *);
#endif /* HAVE_LIBEXPAT */
diff --git a/ext/xml/xml.c b/ext/xml/xml.c
index 2ad53e77e9..f1a3442b6d 100644
--- a/ext/xml/xml.c
+++ b/ext/xml/xml.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -554,9 +554,9 @@ static xml_encoding *xml_get_encoding(const XML_Char *name)
/* }}} */
/* {{{ xml_utf8_encode() */
-PHPAPI zend_string *xml_utf8_encode(const char *s, int len, const XML_Char *encoding)
+PHPAPI zend_string *xml_utf8_encode(const char *s, size_t len, const XML_Char *encoding)
{
- int pos = len;
+ size_t pos = len;
zend_string *str;
unsigned int c;
unsigned short (*encoder)(unsigned char) = NULL;
@@ -605,7 +605,7 @@ PHPAPI zend_string *xml_utf8_encode(const char *s, int len, const XML_Char *enco
/* }}} */
/* {{{ xml_utf8_decode() */
-PHPAPI zend_string *xml_utf8_decode(const XML_Char *s, int len, const XML_Char *encoding)
+PHPAPI zend_string *xml_utf8_decode(const XML_Char *s, size_t len, const XML_Char *encoding)
{
size_t pos = 0;
unsigned int c;
@@ -627,7 +627,7 @@ PHPAPI zend_string *xml_utf8_decode(const XML_Char *s, int len, const XML_Char *
str = zend_string_alloc(len, 0);
str->len = 0;
- while (pos < (size_t)len) {
+ while (pos < len) {
int status = FAILURE;
c = php_next_utf8_char((const unsigned char*)s, (size_t) len, &pos, &status);
diff --git a/ext/xml/xml.mak b/ext/xml/xml.mak
index ab60f28eed..b712dea1d6 100644
--- a/ext/xml/xml.mak
+++ b/ext/xml/xml.mak
@@ -4,7 +4,7 @@ PROJECT_ROOT = ..\..
# Module details
MODULE_NAME = php_xml
-MODULE_DESC = "PHP 5 - XML Extension"
+MODULE_DESC = "PHP 7 - XML Extension"
VMAJ = 3
VMIN = 0
VREV = 0
diff --git a/ext/xmlreader/README b/ext/xmlreader/README
index 0d946f62da..f85e4a2121 100644
--- a/ext/xmlreader/README
+++ b/ext/xmlreader/README
@@ -2,4 +2,4 @@ XMLReader represents a reader that provides non-cached,
forward-only access to XML data. It is based upon the
xmlTextReader api from libxml
-This extension is designed to only work under PHP 5.
+This extension is designed to only work under PHP 5+.
diff --git a/ext/xmlreader/php_xmlreader.c b/ext/xmlreader/php_xmlreader.c
index a90f727cb8..43e585dd33 100644
--- a/ext/xmlreader/php_xmlreader.c
+++ b/ext/xmlreader/php_xmlreader.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/xmlreader/php_xmlreader.h b/ext/xmlreader/php_xmlreader.h
index 4107396d39..7a721dcc6f 100644
--- a/ext/xmlreader/php_xmlreader.h
+++ b/ext/xmlreader/php_xmlreader.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/xmlreader/xmlreader.dsp b/ext/xmlreader/xmlreader.dsp
deleted file mode 100644
index 7b21518ba3..0000000000
--- a/ext/xmlreader/xmlreader.dsp
+++ /dev/null
@@ -1,114 +0,0 @@
-# Microsoft Developer Studio Project File - Name="xmlreader" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=xmlreader - Win32 Release_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "xmlreader.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "xmlreader.mak" CFG="xmlreader - Win32 Release_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "xmlreader - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "xmlreader - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "xmlreader - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "xmlreader___Win32_Debug_TS"
-# PROP BASE Intermediate_Dir "xmlreader___Win32_Debug_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "XMLREADER_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /GX /ZI /Od /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "XMLREADER_EXPORTS" /D "COMPILE_DL_XMLREADER" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D "LIBXML_THREAD_ENABLED" /FR /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 php5ts_debug.lib resolv.lib kernel32.lib user32.lib gdi32.lib winspool.lib /nologo /dll /debug /machine:I386 /nodefaultlib:"msvcrt" /out:"..\..\Debug_TS/php_xmlreader.dll" /libpath:"..\..\Debug_TS" /libpath:"..\..\..\bindlib_w32\Release"
-
-!ELSEIF "$(CFG)" == "xmlreader - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "xmlreader___Win32_Release_TS0"
-# PROP BASE Intermediate_Dir "xmlreader___Win32_Release_TS0"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MDd /W3 /GX /ZI /Od /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "XMLREADER_EXPORTS" /D "COMPILE_DL_XSL" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D "LIBXML_THREAD_ENABLED" /FR /YX /FD /GZ /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /D ZEND_DEBUG=0 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "XMLREADER_EXPORTS" /D "COMPILE_DL_XSL" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D "LIBXML_THREAD_ENABLED" /YX /FD /GZ /c
-# SUBTRACT CPP /Fr
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 php5ts_debug.lib resolv.lib kernel32.lib user32.lib gdi32.lib winspool.lib /nologo /dll /debug /machine:I386 /nodefaultlib:"msvcrt" /out:"..\..\Debug_TS/php_xmlreader.dll" /libpath:"..\..\Debug_TS" /libpath:"..\..\..\bindlib_w32\Release"
-# ADD LINK32 php5ts.lib resolv.lib kernel32.lib user32.lib gdi32.lib winspool.lib /nologo /dll /incremental:no /machine:I386 /out:"..\..\Release_TS/php_xmlreader.dll" /libpath:"..\..\Debug_TS" /libpath:"..\..\..\bindlib_w32\Release"
-# SUBTRACT LINK32 /debug
-
-!ENDIF
-
-# Begin Target
-
-# Name "xmlreader - Win32 Debug_TS"
-# Name "xmlreader - Win32 Release_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\php_xmlreader.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_xmlreader.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# End Target
-# End Project
diff --git a/ext/xmlrpc/php_xmlrpc.h b/ext/xmlrpc/php_xmlrpc.h
index 286711b505..4e059788de 100644
--- a/ext/xmlrpc/php_xmlrpc.h
+++ b/ext/xmlrpc/php_xmlrpc.h
@@ -35,7 +35,7 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/xmlrpc/xmlrpc-epi-php.c b/ext/xmlrpc/xmlrpc-epi-php.c
index b5b7e87161..d43a31be11 100644
--- a/ext/xmlrpc/xmlrpc-epi-php.c
+++ b/ext/xmlrpc/xmlrpc-epi-php.c
@@ -35,7 +35,7 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -472,7 +472,7 @@ static void set_output_options(php_output_options* options, zval* output_opts)
static XMLRPC_VECTOR_TYPE determine_vector_type (HashTable *ht)
{
int bArray = 0, bStruct = 0, bMixed = 0;
- unsigned long num_index, last_num = 0;
+ zend_ulong num_index, last_num = 0;
zend_string* my_key;
ZEND_HASH_FOREACH_KEY(ht, num_index, my_key) {
@@ -541,7 +541,7 @@ static XMLRPC_VALUE PHP_to_XMLRPC_worker (const char* key, zval* in_val, int dep
break;
case xmlrpc_vector:
{
- unsigned long num_index;
+ zend_ulong num_index;
zval* pIter;
zend_string* my_key;
HashTable *ht = NULL;
diff --git a/ext/xmlrpc/xmlrpc.dsp b/ext/xmlrpc/xmlrpc.dsp
deleted file mode 100644
index 8c455d3fcd..0000000000
--- a/ext/xmlrpc/xmlrpc.dsp
+++ /dev/null
@@ -1,211 +0,0 @@
-# Microsoft Developer Studio Project File - Name="xmlrpc" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=xmlrpc - Win32 Debug_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "xmlrpc.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "xmlrpc.mak" CFG="xmlrpc - Win32 Debug_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "xmlrpc - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "xmlrpc - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "xmlrpc - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "XMLRPC_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /I "libxmlrpc" /I "..\..\bundle\expat" /D HAVE_XMLRPC=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D ZEND_DEBUG=1 /D ZTS=1 /D COMPILE_DL_XMLRPC=1 /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "XMLRPC_EXPORTS" /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x1009 /d "_DEBUG"
-# ADD RSC /l 0x1009 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 php5ts_debug.lib expat.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /out:"..\..\Debug_TS/php_xmlrpc.dll" /pdbtype:sept /libpath:"..\..\Debug_TS"
-
-!ELSEIF "$(CFG)" == "xmlrpc - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "XMLRPC_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\TSRM" /I "libxmlrpc" /I "..\..\bundle\expat" /D HAVE_XMLRPC=1 /D "ZEND_WIN32" /D ZEND_DEBUG=0 /D "PHP_WIN32" /D ZTS=1 /D COMPILE_DL_XMLRPC=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "XMLRPC_EXPORTS" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x1009 /d "NDEBUG"
-# ADD RSC /l 0x1009 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 php5ts.lib expat.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_xmlrpc.dll" /libpath:"..\..\Release_TS"
-
-!ENDIF
-
-# Begin Target
-
-# Name "xmlrpc - Win32 Debug_TS"
-# Name "xmlrpc - Win32 Release_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=".\xmlrpc-epi-php.c"
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_xmlrpc.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# Begin Group "libxmlrpc"
-
-# PROP Default_Filter ""
-# Begin Source File
-
-SOURCE=.\libxmlrpc\base64.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\base64.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\encodings.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\encodings.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\queue.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\queue.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\simplestring.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\simplestring.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\system_methods.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\system_methods_private.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\xml_element.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\xml_element.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\xml_to_dandarpc.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\xml_to_dandarpc.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\xml_to_soap.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\xml_to_soap.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\xml_to_xmlrpc.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\xml_to_xmlrpc.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\xmlrpc.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\xmlrpc.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\xmlrpc_introspection.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\xmlrpc_introspection.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\xmlrpc_introspection_private.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\libxmlrpc\xmlrpc_private.h
-# End Source File
-# End Group
-# End Target
-# End Project
diff --git a/ext/xmlwriter/TODO b/ext/xmlwriter/TODO
index bfc895d769..858ad6be27 100644
--- a/ext/xmlwriter/TODO
+++ b/ext/xmlwriter/TODO
@@ -1,4 +1,4 @@
-- Fix up config file for PHP 5 to use libxml extension configuration
+- Fix up config file for PHP 7 to use libxml extension configuration
- Add tests for Namespace functions/methods
- Sync with xmlwriter (new dtd func?)
- Write documentations in docbook
diff --git a/ext/xmlwriter/php_xmlwriter.c b/ext/xmlwriter/php_xmlwriter.c
index becfbc2157..6e3475e8d0 100644
--- a/ext/xmlwriter/php_xmlwriter.c
+++ b/ext/xmlwriter/php_xmlwriter.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/xmlwriter/php_xmlwriter.h b/ext/xmlwriter/php_xmlwriter.h
index a4f43baaf5..fc00a9d578 100644
--- a/ext/xmlwriter/php_xmlwriter.h
+++ b/ext/xmlwriter/php_xmlwriter.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/xmlwriter/xmlwriter.dsp b/ext/xmlwriter/xmlwriter.dsp
deleted file mode 100644
index e5eca77be5..0000000000
--- a/ext/xmlwriter/xmlwriter.dsp
+++ /dev/null
@@ -1,113 +0,0 @@
-# Microsoft Developer Studio Project File - Name="xmlwriter" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=xmlwriter - Win32 Release_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "xmlwriter.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "xmlwriter.mak" CFG="xmlwriter - Win32 Release_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "xmlwriter - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "xmlwriter - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "xmlwriter - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "XMLWRITER_EXPORTS" /D "COMPILE_DL_XMLWRITER" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D "LIBXML_THREAD_ENABLED" /FR /YX /FD /GZ /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /D ZEND_DEBUG=0 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "XMLWRITER_EXPORTS" /D "COMPILE_DL_XMLWRITER" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_XMLWRITER=1 /D "LIBXML_STATIC" /YX /FD /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib /nologo /dll /debug /machine:I386 /nodefaultlib:"msvcrt" /out:"..\..\Debug_TS/php_xmlwriter.dll" /libpath:"..\..\Debug_TS" /libpath:"..\..\..\bindlib_w32\Release"
-# ADD LINK32 wsock32.lib php4ts.lib libxml2_a.lib iconv.lib resolv.lib kernel32.lib user32.lib gdi32.lib winspool.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_xmlwriter.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline" /libpath:"..\..\..\bindlib_w32\Release"
-# SUBTRACT LINK32 /debug
-
-!ELSEIF "$(CFG)" == "xmlwriter - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "xmlwriter___Win32_Debug_TS"
-# PROP BASE Intermediate_Dir "xmlwriter___Win32_Debug_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "XMLWRITER_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /GX /ZI /Od /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "XMLWRITER_EXPORTS" /D "COMPILE_DL_XMLWRITER" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D "LIBXML_STATIC" /FR /YX /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 wsock32.lib php4ts_debug.lib libxml2_a.lib iconv.lib resolv.lib kernel32.lib user32.lib gdi32.lib winspool.lib /nologo /dll /debug /machine:I386 /nodefaultlib:"msvcrt" /out:"..\..\Debug_TS/php_xmlwriter.dll" /libpath:"..\..\Debug_TS" /libpath:"..\..\..\bindlib_w32\Release"
-
-!ENDIF
-
-# Begin Target
-
-# Name "xmlwriter - Win32 Release_TS"
-# Name "xmlwriter - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\php_xmlwriter.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_xmlwriter.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# End Target
-# End Project
diff --git a/ext/xsl/php_xsl.c b/ext/xsl/php_xsl.c
index bda02498ed..2763d83326 100644
--- a/ext/xsl/php_xsl.c
+++ b/ext/xsl/php_xsl.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/xsl/php_xsl.h b/ext/xsl/php_xsl.h
index 375cb32fb0..b6603321a3 100644
--- a/ext/xsl/php_xsl.h
+++ b/ext/xsl/php_xsl.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/xsl/xsl.dsp b/ext/xsl/xsl.dsp
deleted file mode 100644
index ff7257d161..0000000000
--- a/ext/xsl/xsl.dsp
+++ /dev/null
@@ -1,120 +0,0 @@
-# Microsoft Developer Studio Project File - Name="xsl" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=xsl - Win32 Debug_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "xsl.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "xsl.mak" CFG="xsl - Win32 Debug_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "xsl - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "xsl - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "xsl - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "XSL_EXPORTS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /D ZEND_DEBUG=0 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "COMPILE_DL_XSL" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D "LIBXSLT_STATIC" /D "LIBEXSLT_STATIC" /D "LIBXML_THREAD_ENABLED" /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /machine:I386
-# ADD LINK32 wsock32.lib php5ts.lib libxslt_a.lib libexslt_a.lib resolv.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_xsl.dll" /implib:".Release_TS/php_xsl.lib" /libpath:"..\..\Release_TS" /libpath:"..\..\Release_TS_Inline" /libpath:"..\..\..\bindlib_w32\Release"
-# SUBTRACT LINK32 /pdb:none
-
-!ELSEIF "$(CFG)" == "xsl - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "XSL_EXPORTS" /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /GX /ZI /Od /I "..\.." /I "..\..\Zend" /I "..\..\TSRM" /I "..\..\main" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "XSL_EXPORTS" /D "COMPILE_DL_XSL" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D "LIBXSLT_STATIC" /D "LIBEXSLT_STATIC" /D "LIBXML_THREAD_ENABLED" /FR /YX /FD /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 php5ts_debug.lib libxslt_a.lib libexslt_a.lib resolv.lib kernel32.lib user32.lib gdi32.lib winspool.lib /nologo /dll /debug /machine:I386 /nodefaultlib:"msvcrt" /out:"..\..\Debug_TS/php_xsl.dll" /libpath:"..\..\Debug_TS" /libpath:"..\..\..\bindlib_w32\Release" /libpath:"..\..\..\php_build\lib\libxslt"
-
-!ENDIF
-
-# Begin Target
-
-# Name "xsl - Win32 Release_TS"
-# Name "xsl - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\php_xsl.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\xsltprocessor.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_xsl.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\xsl_fe.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# End Target
-# End Project
diff --git a/ext/xsl/xsl_fe.h b/ext/xsl/xsl_fe.h
index 89726da724..e987554a4d 100644
--- a/ext/xsl/xsl_fe.h
+++ b/ext/xsl/xsl_fe.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/xsl/xsltprocessor.c b/ext/xsl/xsltprocessor.c
index cd828c75a0..20af855aa4 100644
--- a/ext/xsl/xsltprocessor.c
+++ b/ext/xsl/xsltprocessor.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -791,7 +791,7 @@ PHP_FUNCTION(xsl_xsltprocessor_set_parameter)
intern = Z_XSL_P(id);
- ZVAL_STR(&new_string, zend_string_copy(value));
+ ZVAL_STR_COPY(&new_string, value);
zend_hash_update(intern->parameter, name, &new_string);
RETURN_TRUE;
diff --git a/ext/zip/lib/config.h b/ext/zip/lib/config.h
index 8c11baa5e2..3d524f3923 100644
--- a/ext/zip/lib/config.h
+++ b/ext/zip/lib/config.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/zip/lib/zip_set_name.c b/ext/zip/lib/zip_set_name.c
index 02fa1272d6..4793c54534 100644
--- a/ext/zip/lib/zip_set_name.c
+++ b/ext/zip/lib/zip_set_name.c
@@ -58,7 +58,7 @@ _zip_set_name(struct zip *za, zip_uint64_t idx, const char *name, zip_flags_t fl
return -1;
}
- if (name && strlen(name) > 0) {
+ if (name && name[0] != '\0') {
/* TODO: check for string too long */
if ((str=_zip_string_new((const zip_uint8_t *)name, (zip_uint16_t)strlen(name), flags, &za->error)) == NULL)
return -1;
diff --git a/ext/zip/php_zip.c b/ext/zip/php_zip.c
index 734ee19d0e..4accc22e30 100644
--- a/ext/zip/php_zip.c
+++ b/ext/zip/php_zip.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -956,7 +956,7 @@ static HashTable *php_zip_get_properties(zval *object TSRMLS_DC)/* {{{ */
HashTable *props;
zip_prop_handler *hnd;
zend_string *key;
- ulong num_key;
+ zend_ulong num_key;
obj = Z_ZIP_P(object);
props = zend_std_get_properties(object TSRMLS_CC);
@@ -1609,9 +1609,11 @@ static void php_zip_add_from_pattern(INTERNAL_FUNCTION_PARAMETERS, int type) /*
RETURN_FALSE;
}
- if (remove_path && remove_path_len > 1 && (remove_path[strlen(remove_path) - 1] == '/' ||
- remove_path[strlen(remove_path) - 1] == '\\')) {
- remove_path[strlen(remove_path) - 1] = '\0';
+ if (remove_path && remove_path_len > 1) {
+ size_t real_len = strlen(remove_path);
+ if (real_len > 1 && remove_path[real_len - 1] == '/' || remove_path[real_len - 1] == '\\') {
+ remove_path[real_len - 1] = '\0';
+ }
}
if (type == 1) {
diff --git a/ext/zip/php_zip.h b/ext/zip/php_zip.h
index 15c085271a..7fab823297 100644
--- a/ext/zip/php_zip.h
+++ b/ext/zip/php_zip.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -76,11 +76,11 @@ typedef struct _ze_zip_read_rsrc {
/* Extends zend object */
typedef struct _ze_zip_object {
struct zip *za;
- int buffers_cnt;
char **buffers;
HashTable *prop_handler;
char *filename;
int filename_len;
+ int buffers_cnt;
zend_object zo;
} ze_zip_object;
diff --git a/ext/zip/zip_stream.c b/ext/zip/zip_stream.c
index 44d5507b77..c542340170 100644
--- a/ext/zip/zip_stream.c
+++ b/ext/zip/zip_stream.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/zlib/php_zlib.h b/ext/zlib/php_zlib.h
index f76e4c2266..ba829b5888 100644
--- a/ext/zlib/php_zlib.h
+++ b/ext/zlib/php_zlib.h
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -49,13 +49,13 @@ typedef struct _php_zlib_context {
ZEND_BEGIN_MODULE_GLOBALS(zlib)
/* variables for transparent gzip encoding */
- int compression_coding;
zend_long output_compression;
zend_long output_compression_level;
char *output_handler;
php_zlib_context *ob_gzhandler;
zend_long output_compression_default;
zend_bool handler_registered;
+ int compression_coding;
ZEND_END_MODULE_GLOBALS(zlib);
php_stream *php_stream_gzopen(php_stream_wrapper *wrapper, const char *path, const char *mode, int options, char **opened_path, php_stream_context *context STREAMS_DC TSRMLS_DC);
diff --git a/ext/zlib/zlib.c b/ext/zlib/zlib.c
index 8e7bd6c40c..000b96ad8e 100644
--- a/ext/zlib/zlib.c
+++ b/ext/zlib/zlib.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
diff --git a/ext/zlib/zlib.dsp b/ext/zlib/zlib.dsp
deleted file mode 100644
index 8986bc6f05..0000000000
--- a/ext/zlib/zlib.dsp
+++ /dev/null
@@ -1,121 +0,0 @@
-# Microsoft Developer Studio Project File - Name="zlib" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=zlib - Win32 Release_TS
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "zlib.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "zlib.mak" CFG="zlib - Win32 Release_TS"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "zlib - Win32 Release_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "zlib - Win32 Debug_TS" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "zlib - Win32 Release_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release_TS"
-# PROP BASE Intermediate_Dir "Release_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release_TS"
-# PROP Intermediate_Dir "Release_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\..\TSRM" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "COMPILE_DL_ZLIB" /D ZTS=1 /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\php_build\includes" /D ZEND_DEBUG=0 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ZLIB_EXPORTS" /D "COMPILE_DL_ZLIB" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_ZLIB=1 /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib /nologo /dll /machine:I386
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts.lib zlib.lib /nologo /dll /machine:I386 /out:"..\..\Release_TS/php_zlib.dll" /libpath:"..\..\Release_TS" /libpath:"..\..\..\php_build\zlib\Release" /libpath:"..\..\Release_TS_Inline"
-
-!ELSEIF "$(CFG)" == "zlib - Win32 Debug_TS"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Debug_TS"
-# PROP BASE Intermediate_Dir "Debug_TS"
-# PROP BASE Ignore_Export_Lib 0
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Debug_TS"
-# PROP Intermediate_Dir "Debug_TS"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MT /W3 /GX /O2 /I "..\.." /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "COMPILE_DL_ZLIB" /D ZTS=1 /YX /FD /c
-# ADD CPP /nologo /MDd /W3 /GX /O2 /I "..\.." /I "..\..\main" /I "..\..\Zend" /I "..\..\..\bindlib_w32" /I "..\..\TSRM" /I "..\..\..\php_build\includes" /D ZEND_DEBUG=1 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "_USRDLL" /D "ZLIB_EXPORTS" /D "COMPILE_DL_ZLIB" /D ZTS=1 /D "ZEND_WIN32" /D "PHP_WIN32" /D HAVE_ZLIB=1 /FR /YX /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x406 /d "NDEBUG"
-# ADD RSC /l 0x406 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts_debug.lib /nologo /dll /machine:I386
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib php5ts_debug.lib zlib.lib /nologo /dll /machine:I386 /out:"..\..\Debug_TS/php_zlib.dll" /libpath:"..\..\Debug_TS" /libpath:"..\..\..\php_build\zlib\Debug"
-
-!ENDIF
-
-# Begin Target
-
-# Name "zlib - Win32 Release_TS"
-# Name "zlib - Win32 Debug_TS"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\zlib.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\zlib_fopen_wrapper.c
-# End Source File
-# Begin Source File
-
-SOURCE=.\zlib_filter.c
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\php_zlib.h
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# End Group
-# End Target
-# End Project
diff --git a/ext/zlib/zlib_filter.c b/ext/zlib/zlib_filter.c
index 53bc2e4269..6966c2a9ff 100644
--- a/ext/zlib/zlib_filter.c
+++ b/ext/zlib/zlib_filter.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -25,12 +25,12 @@
/* Passed as opaque in malloc callbacks */
typedef struct _php_zlib_filter_data {
- int persistent;
z_stream strm;
char *inbuf;
size_t inbuf_len;
char *outbuf;
size_t outbuf_len;
+ int persistent;
zend_bool finished;
} php_zlib_filter_data;
diff --git a/ext/zlib/zlib_fopen_wrapper.c b/ext/zlib/zlib_fopen_wrapper.c
index 713a6ecfb2..796b8a54e0 100644
--- a/ext/zlib/zlib_fopen_wrapper.c
+++ b/ext/zlib/zlib_fopen_wrapper.c
@@ -1,6 +1,6 @@
/*
+----------------------------------------------------------------------+
- | PHP Version 5 |
+ | PHP Version 7 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2014 The PHP Group |
+----------------------------------------------------------------------+
@@ -37,13 +37,14 @@ static size_t php_gziop_read(php_stream *stream, char *buf, size_t count TSRMLS_
struct php_gz_stream_data_t *self = (struct php_gz_stream_data_t *) stream->abstract;
int read;
+ /* XXX this needs to be looped for the case count > UINT_MAX */
read = gzread(self->gz_file, buf, count);
if (gzeof(self->gz_file)) {
stream->eof = 1;
}
- return (read < 0) ? 0 : read;
+ return (size_t)((read < 0) ? 0 : read);
}
static size_t php_gziop_write(php_stream *stream, const char *buf, size_t count TSRMLS_DC)
@@ -51,9 +52,10 @@ static size_t php_gziop_write(php_stream *stream, const char *buf, size_t count
struct php_gz_stream_data_t *self = (struct php_gz_stream_data_t *) stream->abstract;
int wrote;
+ /* XXX this needs to be looped for the case count > UINT_MAX */
wrote = gzwrite(self->gz_file, (char *) buf, count);
- return (wrote < 0) ? 0 : wrote;
+ return (size_t)((wrote < 0) ? 0 : wrote);
}
static int php_gziop_seek(php_stream *stream, zend_off_t offset, int whence, zend_off_t *newoffs TSRMLS_DC)
diff --git a/ext/zlib/zlib_win32_howto.txt b/ext/zlib/zlib_win32_howto.txt
index a4e01a4845..0c46a88831 100644
--- a/ext/zlib/zlib_win32_howto.txt
+++ b/ext/zlib/zlib_win32_howto.txt
@@ -7,7 +7,7 @@ php_build\zlib\include\zlib.h
php_build\zlib\include\zconf.h
php_build\zlib\lib\zlibstat.lib
-php_build is a directory at the same level as php5.
+php_build is a directory at the same level as php7.
Start Visual Studio, load php_modules.dsw, select the ZLIB projects, and build
it.