summaryrefslogtreecommitdiff
path: root/ext/xmlwriter/php_xmlwriter.c
Commit message (Collapse)AuthorAgeFilesLines
* Merge branch 'PHP-7.3' into PHP-7.4Christoph M. Becker2020-02-031-14/+21
|\ | | | | | | | | * PHP-7.3: Fix #79191: Error in SoapClient ctor disables DOMDocument::save()
| * Fix #79191: Error in SoapClient ctor disables DOMDocument::save()Christoph M. Becker2020-02-031-14/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The culprit is the too restrictive fix for bug #71536, which prevents `php_libxml_streams_IO_write()` from properly executing when unclean shutdown is flagged. A *more* suitable solution is to move the `xmlwriter_free_resource_ptr()` call from the `free_obj` handler to an added `dtor_obj` handler, to avoid to write to a closed stream in case of late object freeing. This makes the `EG(active)` guard superfluous. We also fix bug79029.phpt which has to use different variables for the three parts to actually check the original shutdown issue. Thanks to bwoebi and daverandom for helping to investigate this issue.
| * Fixed bug #79029 (Use After Free's in XMLReader / XMLWriter).Xinchen Hui2019-12-251-7/+9
| | | | | | | | | | | | | | | | We backport the fix PHP 7.3, since this branch is affected as well. (cherry picked from commit b5e004379647bd1ebb75eb2eac8826fb6abdd3d8) (cherry picked from commit e36daa6927c05d2e687bb77495ef206cde118b33) (cherry picked from commit 2704ee6844c03348de9d15e74646d09007ef0f7c)
* | Partial fix for bug #79029Xinchen Hui2019-12-251-7/+9
| |
* | Add missing argument checksChristoph M. Becker2019-09-031-0/+6
| | | | | | | | | | These functions don't expect any arguments, so we check that none are given.
* | Use zend_parse_parameters_none() in XmlWriter::openMemory()Nikita Popov2019-02-201-0/+4
| | | | | | | | And fix incorrect uses in tests
* | Remove local variablesPeter Kokot2019-02-031-9/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch removes the so called local variables defined per file basis for certain editors to properly show tab width, and similar settings. These are mainly used by Vim and Emacs editors yet with recent changes the once working definitions don't work anymore in Vim without custom plugins or additional configuration. Neither are these settings synced across the PHP code base. A simpler and better approach is EditorConfig and fixing code using some code style fixing tools in the future instead. This patch also removes the so called modelines for Vim. Modelines allow Vim editor specifically to set some editor configuration such as syntax highlighting, indentation style and tab width to be set in the first line or the last 5 lines per file basis. Since the php test files have syntax highlighting already set in most editors properly and EditorConfig takes care of the indentation settings, this patch removes these as well for the Vim 6.0 and newer versions. With the removal of local variables for certain editors such as Emacs and Vim, the footer is also probably not needed anymore when creating extensions using ext_skel.php script. Additionally, Vim modelines for setting php syntax and some editor settings has been removed from some *.phpt files. All these are mostly not relevant for phpt files neither work properly in the middle of the file.
* | Remove yearly range from copyright noticeZeev Suraski2019-01-301-1/+1
| |
* | Bump minimum libxml version to 2.7.6Nikita Popov2018-09-231-10/+0
| | | | | | | | Released Oct 2009, part of RHEL 6.
* | Remove checks for libxml < 2.6.11Nikita Popov2018-09-161-26/+0
|/ | | | These are below our minimum version requirement.
* Remove unused Git attributes identPeter Kokot2018-07-251-2/+0
| | | | | | | | | | | | | | | The $Id$ keywords were used in Subversion where they can be substituted with filename, last revision number change, last changed date, and last user who changed it. In Git this functionality is different and can be done with Git attribute ident. These need to be defined manually for each file in the .gitattributes file and are afterwards replaced with 40-character hexadecimal blob object name which is based only on the particular file contents. This patch simplifies handling of $Id$ keywords by removing them since they are not used anymore.
* Export standard object handlers, to avoid indirect accessDmitry Stogov2018-05-311-1/+1
|
* year++Xinchen Hui2018-01-021-1/+1
|
* Add zend_object_alloc() APINikita Popov2017-11-251-1/+1
| | | | | | | | | | | Using ecalloc() to create objects is expensive, because the dynamic-size memset() is unreasonably slow. Make sure we only zero the main object structure with known size, as the properties are intialized separately anyway. Technically we do not need to zero the embedded zend_object structure either, but as long as the memset argument is constant, a couple more bytes don't really matter.
* Update copyright headers to 2017Sammy Kaye Powers2017-01-021-1/+1
|
* Fixed compilation warningsDmitry Stogov2016-06-221-3/+5
|
* Merge branch 'PHP-5.6' into PHP-7.0Lior Kaplan2016-01-011-1/+1
|\ | | | | | | | | * PHP-5.6: Happy new year (Update copyright to 2016)
| * Happy new year (Update copyright to 2016)Lior Kaplan2016-01-011-1/+1
| |
* | Internal function argumensts cleanup (strict_types)Xinchen Hui2015-12-121-1/+1
| |
* | Merge branch 'PHP-5.6'Stanislav Malyshev2015-04-141-2/+2
|\ \ | |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * PHP-5.6: (27 commits) fix non-standard C update NEWS 5.4.41 next fix CVE num update NEWS Fix bug #69441 (Buffer Overflow when parsing tar/zip/phar in phar_set_inode) fix test fix type in fix for #69085 fix memory leak & add test Fix tests fix CVE num Fix bug #69337 (php_stream_url_wrap_http_ex() type-confusion vulnerability) Fix test Additional fix for bug #69324 More fixes for bug #69152 Fixed bug #69353 (Missing null byte checks for paths in various PHP extensions) Fixed bug #69324 (Buffer Over-read in unserialize when parsing Phar) Fixed bug #69316 (Use-after-free in php_curl related to CURLOPT_FILE/_INFILE/_WRITEHEADER) Fix bug #68486 and bug #69218 (segfault in apache2handler with apache 2.4) Fix bug #68819 (Fileinfo on specific file causes spurious OOM and/or segfault) ... Conflicts: Zend/zend_exceptions.c ext/curl/interface.c ext/dom/document.c ext/fileinfo/libmagic/softmagic.c ext/gd/gd.c ext/hash/hash.c ext/pgsql/pgsql.c ext/phar/phar.c ext/phar/phar_internal.h ext/standard/http_fopen_wrapper.c ext/standard/link.c ext/standard/streamsfuncs.c ext/xmlwriter/php_xmlwriter.c ext/zlib/zlib.c
| * Merge branch 'PHP-5.5-security' into PHP-5.5.24Stanislav Malyshev2015-04-121-1/+1
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * PHP-5.5-security: (22 commits) Fixed bug #69316 (Use-after-free in php_curl related to CURLOPT_FILE/_INFILE/_WRITEHEADER) Fix bug #68486 and bug #69218 (segfault in apache2handler with apache 2.4) Fix bug #68819 (Fileinfo on specific file causes spurious OOM and/or segfault) updated NEWS added test for bug #69354 revert skipif, this should run everywhere further ODBC 3.0 compliance more compliance with the ODBC 3.0 test fixes Prevent GC from changing zval or object 'color' before they are actually inserted into possible roots buffer. sigh, can't even copypaste without screwing up oop, put both the error number and message for both db object to the error message test fixes Fixed bug #69281 (opcache_is_script_cached no longer works) Fix typo: unitialized -> uninitialized Fix typo: unitialized -> uninitialized Fixed bug #68739 (Missing break / control flow). Fixed bug #68740 (NULL Pointer Dereference). Fixed bug #68677 (Use After Free). Fixed bug #68739 (Missing break / control flow in curl) Fixed bug #68740 (NULL Pointer Dereference) Fixed bug #68677 (Use After Free in OPcache) ... Conflicts: configure.in ext/curl/tests/bug69316.phpt main/php_version.h
| * \ Merge branch 'PHP-5.4.40' into PHP-5.5.24Stanislav Malyshev2015-04-111-2/+2
| |\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * PHP-5.4.40: Additional fix for bug #69324 More fixes for bug #69152 Fixed bug #69353 (Missing null byte checks for paths in various PHP extensions) Fixed bug #69324 (Buffer Over-read in unserialize when parsing Phar) Fixed bug #69316 (Use-after-free in php_curl related to CURLOPT_FILE/_INFILE/_WRITEHEADER) Fix bug #68486 and bug #69218 (segfault in apache2handler with apache 2.4) Fix bug #68819 (Fileinfo on specific file causes spurious OOM and/or segfault) Fixed bug #68901 (use after free) Fixed bug #68740 (NULL Pointer Dereference) Fix bug #66550 (SQLite prepared statement use-after-free) Better fix for #68601 for perf https://bitbucket.org/libgd/gd-libgd/commits/81e9a993f2893d651d225646378e3fd1b7465467 Fix bug #68601 buffer read overflow in gd_gif_in.c Revert "Merge branch 'PHP-5.4' of https://git.php.net/repository/php-src into PHP-5.4" Fixed bug #69293 Add ZEND_ARG_CALLABLE_INFO to allow internal function to type hint against callable.
| | * | Fixed bug #69353 (Missing null byte checks for paths in various PHP extensions)Stanislav Malyshev2015-04-111-2/+2
| | | |
| | * | Bump yearXinchen Hui2014-01-031-1/+1
| | | |
| | * | Happy New YearXinchen Hui2013-01-011-1/+1
| | | |
| | * | Merge branch 'PHP-5.3' into PHP-5.4Felipe Pena2012-05-181-0/+2
| | |\ \ | | | | | | | | | | | | | | | | | | | | * PHP-5.3: - Fixed bug #62064 (memory leak in the XML Writer module)
| | | * | - Fixed bug #62064 (memory leak in the XML Writer module)Felipe Pena2012-05-181-0/+2
| | | | |
| | | * | - Year++Felipe Pena2012-01-011-1/+1
| | | | |
| | | * | - Make usage of new PHP_FE_END macroFelipe Pena2011-07-251-1/+1
| | | | |
| | | * | - Year++Felipe Pena2011-01-011-1/+1
| | | | |
| | * | | - Year++Felipe Pena2012-01-011-1/+1
| | | | |
| | * | | - Make usage of new PHP_FE_END macroFelipe Pena2011-07-251-1/+1
| | | | |
* | | | | Merge branch 'PHP-5.6'Lior Kaplan2015-04-011-1/+1
|\ \ \ \ \ | | |_|_|/ | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * PHP-5.6: Fix typo: unitialized -> uninitialized Fix typo: unitialized -> uninitialized Conflicts: ext/xmlwriter/php_xmlwriter.c
| * | | | Fix typo: unitialized -> uninitializedLior Kaplan2015-04-011-1/+1
| |/ / /
| * | | Bump yearXinchen Hui2015-01-151-1/+1
| | | |
| * | | Bump yearXinchen Hui2014-01-031-1/+1
| | | |
* | | | cleanup mod version macros and mod defs, round xAnatol Belski2015-03-231-1/+1
| | | |
* | | | Move zend_object->guards into additional slot of ↵Dmitry Stogov2015-02-041-1/+1
| | | | | | | | | | | | | | | | zend_object->properties_table[]. As result size of objects without __get/__set/__unset/__isset magic methods is reduced.
* | | | Cleanup resource handling APIsXinchen Hui2015-02-021-23/+62
| | | |
* | | | bump yearXinchen Hui2015-01-151-1/+1
| | | |
* | | | trailing whitespace removalStanislav Malyshev2015-01-101-56/+56
| | | |
* | | | first shot remove TSRMLS_* thingsAnatol Belski2014-12-131-60/+60
| | | |
* | | | s/PHP 5/PHP 7/Johannes Schlüter2014-09-191-1/+1
| | | |
* | | | first show to make 's' work with size_tAnatol Belski2014-08-271-17/+30
| | | |
* | | | master renames phase 3Anatol Belski2014-08-251-1/+1
| | | |
* | | | master renames phase 1Anatol Belski2014-08-251-1/+1
| | | |
* | | | ported xsl, xml reader and writerAnatol Belski2014-08-191-1/+1
| | | |
* | | | basic macro replacements, all at onceAnatol Belski2014-08-191-1/+1
| | | |
* | | | Use self instead of this(keyword)Xinchen Hui2014-05-041-68/+68
| | | |
* | | | Port XMLWriterXinchen Hui2014-05-041-228/+61
| | | |