History log of /PHP-8.2/ext/xsl/xsltprocessor.c (Results 1 – 25 of 180)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
# e2d97314 06-Dec-2023 Niels Dossche <7771979+nielsdos@users.noreply.github.com>

Backport deprecation warning ignores to unbreak CI

In master I use ZEND_DIAGNOSTIC_IGNORED_START, but that doesn't exist on
8.2 or 8.3 (8.3 has a similar macro though).
So to unbreak

Backport deprecation warning ignores to unbreak CI

In master I use ZEND_DIAGNOSTIC_IGNORED_START, but that doesn't exist on
8.2 or 8.3 (8.3 has a similar macro though).
So to unbreak CI I just made a variation of this directly in the
php_libxml.h header.

See https://github.com/php/php-src/commit/683e78786070ab77d33f7787598ac1b90d68390a#commitcomment-134301083

Closes GH-12887.

show more ...

# 304e4828 02-Nov-2023 Niels Dossche <7771979+nielsdos@users.noreply.github.com>

Merge branch 'PHP-8.1' into PHP-8.2

* PHP-8.1:
Fix validation logic of php:function() callbacks in dom and xsl


# 20c9c4a3 02-Nov-2023 Niels Dossche <7771979+nielsdos@users.noreply.github.com>

Fix validation logic of php:function() callbacks in dom and xsl

Two issues:
- Assumed that at least 1 argument (function name) was provided.
- Incorrect error path for the non-callab

Fix validation logic of php:function() callbacks in dom and xsl

Two issues:
- Assumed that at least 1 argument (function name) was provided.
- Incorrect error path for the non-callable case.

Closes GH-12593.

show more ...

# deddf469 31-Jul-2023 Derick Rethans

Merge branch 'PHP-8.1' into PHP-8.2


# 0870ebb8 31-Jul-2023 Derick Rethans

Merge branch 'PHP-8.0' into PHP-8.1


# c283c3ab 15-Jul-2023 Niels Dossche <7771979+nielsdos@users.noreply.github.com>

Sanitize libxml2 globals before parsing

Fixes GHSA-3qrf-m4j2-pcrr.

To parse a document with libxml2, you first need to create a parsing context.
The parsing context contains par

Sanitize libxml2 globals before parsing

Fixes GHSA-3qrf-m4j2-pcrr.

To parse a document with libxml2, you first need to create a parsing context.
The parsing context contains parsing options (e.g. XML_NOENT to substitute
entities) that the application (in this case PHP) can set.
Unfortunately, libxml2 also supports providing default set options.
For example, if you call xmlSubstituteEntitiesDefault(1) then the XML_NOENT
option will be added to the parsing options every time you create a parsing
context **even if the application never requested XML_NOENT**.

Third party extensions can override these globals, in particular the
substitute entity global. This causes entity substitution to be
unexpectedly active.

Fix it by setting the parsing options to a sane known value.
For API calls that depend on global state we introduce
PHP_LIBXML_SANITIZE_GLOBALS() and PHP_LIBXML_RESTORE_GLOBALS().
For other APIs that work directly with a context we introduce
php_libxml_sanitize_parse_ctxt_options().

show more ...

# 90b7bde6 03-Nov-2021 Dmitry Stogov

Use more compact representation for packed arrays.

- for packed arrays we store just an array of zvals without keys.
- the elements of packed array are accessible throuf as ht->arPacked[

Use more compact representation for packed arrays.

- for packed arrays we store just an array of zvals without keys.
- the elements of packed array are accessible throuf as ht->arPacked[i]
instead of ht->arData[i]
- in addition to general ZEND_HASH_FOREACH_* macros, we introduced similar
familied for packed (ZEND_HASH_PACKED_FORECH_*) and real hashes
(ZEND_HASH_MAP_FOREACH_*)
- introduced an additional family of macros to access elements of array
(packed or real hashes) ZEND_ARRAY_ELEMET_SIZE, ZEND_ARRAY_ELEMET_EX,
ZEND_ARRAY_ELEMET, ZEND_ARRAY_NEXT_ELEMENT, ZEND_ARRAY_PREV_ELEMENT
- zend_hash_minmax() prototype was changed to compare only values

Because of smaller data set, this patch may show performance improvement
on some apps and benchmarks that use packed arrays. (~1% on PHP-Parser)

TODO:
- sapi/phpdbg needs special support for packed arrays (WATCH_ON_BUCKET).
- zend_hash_sort_ex() may require converting packed arrays to hash.

show more ...

# e41f7e59 01-Sep-2021 Nikita Popov

Simplify handler invocation in xsltprocessor

# aff36587 29-Jun-2021 Patrick Allaert

Fixed some spaces used instead of tabs

# 01b3fc03 06-May-2021 KsaR

Update http->https in license (#6945)

1. Update: http://www.php.net/license/3_01.txt to https, as there is anyway server header "Location:" to https.
2. Update few license 3.0 to 3.01 as

Update http->https in license (#6945)

1. Update: http://www.php.net/license/3_01.txt to https, as there is anyway server header "Location:" to https.
2. Update few license 3.0 to 3.01 as 3.0 states "php 5.1.1, 4.1.1, and earlier".
3. In some license comments is "at through the world-wide-web" while most is without "at", so deleted.
4. fixed indentation in some files before |

show more ...

# 422d1665 14-Jan-2021 Nikita Popov

Make convert_to_*_ex simple aliases of convert_to_*

Historically, the _ex variants separated the zval first, if a
conversion was necessary. This distinction no longer makes sense
sin

Make convert_to_*_ex simple aliases of convert_to_*

Historically, the _ex variants separated the zval first, if a
conversion was necessary. This distinction no longer makes sense
since PHP 7.

The only difference that was still left is that _ex checked whether
the type is the same first, but the usage of these macros did not
actually distinguish on whether such an inlined check is valuable
or not in a given context.

Also drop the unused convert_to_explicit_type macros.

show more ...

# 2f601d84 28-Sep-2020 Nikita Popov

Promote warnings in ext/xsl

# 41b096b3 25-Sep-2020 Máté Kocsis

Promote a few forgotten warnings to exceptions

Closes GH-6211

# c98d4769 10-Sep-2020 Máté Kocsis

Consolidate new union type ZPP macro names

They will now follow the canonical order of types. Older macros are
left intact due to maintaining BC.

Closes GH-6112

# 3e800e99 24-Aug-2020 Máté Kocsis

Move custom type checks to ZPP

Closes GH-6034

# d92229d8 06-Apr-2020 Nikita Popov

Implement named parameters

From an engine perspective, named parameters mainly add three
concepts:

* The SEND_* opcodes now accept a CONST op2, which is the
argument nam

Implement named parameters

From an engine perspective, named parameters mainly add three
concepts:

* The SEND_* opcodes now accept a CONST op2, which is the
argument name. For now, it is looked up by linear scan and
runtime cached.
* This may leave UNDEF arguments on the stack. To avoid having
to deal with them in other places, a CHECK_UNDEF_ARGS opcode
is used to either replace them with defaults, or error.
* For variadic functions, EX(extra_named_params) are collected
and need to be freed based on ZEND_CALL_HAS_EXTRA_NAMED_PARAMS.

RFC: https://wiki.php.net/rfc/named_params

Closes GH-5357.

show more ...

# 302933da 07-Jul-2020 Nikita Popov

Remove no_separation flag

# 632766a5 07-Jul-2020 Nikita Popov

Disallow separation in a number of callbacks

All of these clearly do not need separation support.

# 2b5de6f8 01-Jul-2020 Max Semenik

Remove proto comments from C files

Closes GH-5758

# 049467d3 25-Jun-2020 Nikita Popov

Avoid warning on exception in xsl ext

# 336998f1 20-May-2020 George Peter Banyard

Fix [-Wundef] warning in XLS extension

# 89d17075 03-May-2020 Máté Kocsis

Fix UNKNOWN default values in ext/xsl

# 68a56483 11-Apr-2020 Máté Kocsis

Generate method entries for ext/xsl

Closes GH-5372

# 9d0eccd9 05-Mar-2020 Máté Kocsis

Perform some maintenance work on the XSL extension

Added stubs, fixed some ZPP, and changed PHP_FALIASes to PHP_METHODs.
Closes GH-5241

# c5f091e4 09-Mar-2020 Nikita Popov

Remove DOM_GET_THIS macro

This macro is trivial, it's more obvious to use ZEND_THIS directly.

12345678