History log of /PHP-8.1/Zend/zend_interfaces.c (Results 1 – 25 of 182)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
# da7a66d6 27-Aug-2023 ju1ius

Prevents double call to internal iterator rewind handler

Closes GH-12060

Signed-off-by: George Peter Banyard <girgias@php.net>


# 8a1f7fa7 19-Sep-2022 Dmitry Stogov

Fix memory leak

Fixes oss-fuzz #51451


Revision tags: php-8.1.7RC1, php-8.1.4RC1
# fb70460d 18-Feb-2022 Christoph M. Becker

Fix GH-7958: Nested CallbackFilterIterator is leaking memory

We implement `zend_object_iterator_funcs.get_gc` for user iterators to
avoid the memory leak.

Closes GH-8107.

Revision tags: php-8.1.3, php-8.1.2RC1, php-8.1.0, php-7.3.33, php-7.3.32, php-7.3.31, php-7.3.30
# 858d0c09 06-Aug-2021 Jeremy Mikola

Include class name in Serializable deprecation message

The deprecation message was originally introduced in 3e6b447 (#6494).

I first encountered this notice when testing the MongoDB

Include class name in Serializable deprecation message

The deprecation message was originally introduced in 3e6b447 (#6494).

I first encountered this notice when testing the MongoDB extension
with PHP 8.1, which produced many duplicate messages that provided
no detail about the particular class that needed to be fixed.

Closes GH-7346.

show more ...

# 6d505d44 22-Jul-2021 Nikita Popov

Add RETURN/RETVAL_COPY_DEREF() macros

These were missing from the set...

I think quite a few of these usages don't actually need the DEREF,
but I've just kept things as is for n

Add RETURN/RETVAL_COPY_DEREF() macros

These were missing from the set...

I think quite a few of these usages don't actually need the DEREF,
but I've just kept things as is for now.

show more ...

# 322864b5 20-Jul-2021 Joe Watkins

Drop serial denier functions

Revision tags: php-7.3.29, php-7.3.28, php-7.3.27, php-7.3.26, php-7.3.26RC1
# 3e6b4479 07-Dec-2020 Nikita Popov

Partially deprecate Serializable

If Serializable is implemented, require that __serialize() and
__unserialize() are implemented as well, else issue a deprecation
warning.

Al

Partially deprecate Serializable

If Serializable is implemented, require that __serialize() and
__unserialize() are implemented as well, else issue a deprecation
warning.

Also deprecate use of PDO::FETCH_SERIALIZE.

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

Closes GH-6494.

show more ...

# 7af3a392 15-Apr-2021 Nikita Popov

Merge branch 'PHP-8.0'

* PHP-8.0:
Handle ref return from Iterator::key()


# 46f9fed0 15-Apr-2021 Nikita Popov

Handle ref return from Iterator::key()

Handle this in the implementation of get_current_key of user_it,
so that the callers may assume that the key is not a reference.

Fixes oss

Handle ref return from Iterator::key()

Handle this in the implementation of get_current_key of user_it,
so that the callers may assume that the key is not a reference.

Fixes oss-fuzz #33018.

show more ...

# 6ce70447 12-Feb-2021 Máté Kocsis

Generate zend class entries based on stubs

Closes GH-6685

# 3e01f5af 15-Jan-2021 Nikita Popov

Replace zend_bool uses with bool

We're starting to see a mix between uses of zend_bool and bool.
Replace all usages with the standard bool type everywhere.

Of course, zend_bool

Replace zend_bool uses with bool

We're starting to see a mix between uses of zend_bool and bool.
Replace all usages with the standard bool type everywhere.

Of course, zend_bool is retained as an alias.

show more ...

Revision tags: php-7.3.25, php-7.3.25RC1, php-7.3.24, php-7.3.24RC1, php-7.3.23
# 3642592a 21-Sep-2020 Nikita Popov

Remove unnecessary check

We should only produce IS_UNDEF if an exception is thrown, this
check is not needed.

Revision tags: php-7.3.23RC1, php-7.3.22
# fa8d9b11 28-Aug-2020 George Peter Banyard

Improve type declarations for Zend APIs

Voidification of Zend API which always succeeded
Use bool argument types instead of int for boolean arguments
Use bool return type for functio

Improve type declarations for Zend APIs

Voidification of Zend API which always succeeded
Use bool argument types instead of int for boolean arguments
Use bool return type for functions which return true/false (1/0)
Use zend_result return type for functions which return SUCCESS/FAILURE as they don't follow normal boolean semantics

Closes GH-6002

show more ...

# 55798e0e 26-Aug-2020 Nikita Popov

Lowercase method name in zend_call_method()

Revision tags: php-7.3.22RC1, php-7.3.21, php-7.3.21RC1, php-7.3.20, php-7.3.20RC1, php-7.3.19, php-7.4.7RC1, php-7.3.19RC1, php-7.3.18RC1, php-7.2.30, php-7.3.17
# 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 ...

# 70501b81 14-Jul-2020 Nikita Popov

Fixed bug #79852

# 312201dc 01-Jul-2020 Nikita Popov

Add get_gc handle for object iterators

Optional handler with the same semantics as the object handler.

# 1314ccbf 26-Jun-2020 Nikita Popov

Cache __unserialize() instead of unserialize()

We should use these cache slots for the new object serialization
mechanism rather than the old one.

# f37138d2 25-Jun-2020 Nikita Popov

Don't use iterator_funcs_ptr if it is null

This avoids ubsan warnings. Alternatively we could always initialize
iterator_funcs_ptr for aggregates, instead of doing so only for
non-in

Don't use iterator_funcs_ptr if it is null

This avoids ubsan warnings. Alternatively we could always initialize
iterator_funcs_ptr for aggregates, instead of doing so only for
non-internal ones.

show more ...

Revision tags: php-7.3.17RC1, php-7.3.18, php-7.3.16, php-7.3.16RC1
# ff19ec2d 26-Feb-2020 Nikita Popov

Introduce InternalIterator

Userland classes that implement Traversable must do so either
through Iterator or IteratorAggregate. The same requirement does
not exist for internal class

Introduce InternalIterator

Userland classes that implement Traversable must do so either
through Iterator or IteratorAggregate. The same requirement does
not exist for internal classes: They can implement the internal
get_iterator mechanism, without exposing either the Iterator or
IteratorAggregate APIs. This makes them usable in get_iterator(),
but incompatible with any Iterator based APIs.

A lot of internal classes do this, because exposing the userland
APIs is simply a lot of work. This patch alleviates this issue by
providing a generic InternalIterator class, which acts as an
adapater between get_iterator and Iterator, and can be easily
used by many internal classes. At the same time, we extend the
requirement that Traversable implies Iterator or IteratorAggregate
to internal classes as well.

Closes GH-5216.

show more ...

# 15846ff1 17-Jun-2020 Nikita Popov

Add ZVAL_OBJ_COPY macro

For the common ZVAL_OBJ + GC_ADDREF pattern.
This mirrors the existing ZVAL_STR_COPY API.

# c23edd2a 10-Jun-2020 Nikita Popov

Remove called_scope inheritance in zend_call_method()

Similar to 097043db2a0d113f89bd26c6f1d7a976d83951a8, but for the
zend_call_method() API. I don't think we ever use this for
stat

Remove called_scope inheritance in zend_call_method()

Similar to 097043db2a0d113f89bd26c6f1d7a976d83951a8, but for the
zend_call_method() API. I don't think we ever use this for
static methods, but this logic shouldn't be there. If you want
to inherit the active LSB scope for some reason, do so explicitly.

show more ...

# 257dbb04 08-Jun-2020 Nikita Popov

Add zend_call_known_function() API family

This adds the following APIs:

void zend_call_known_function(
zend_function *fn, zend_object *object, zend_class_entry *called_scope

Add zend_call_known_function() API family

This adds the following APIs:

void zend_call_known_function(
zend_function *fn, zend_object *object, zend_class_entry *called_scope,
zval *retval_ptr, int param_count, zval *params);

void zend_call_known_instance_method(
zend_function *fn, zend_object *object, zval *retval_ptr, int param_count, zval *params);
void zend_call_known_instance_method_with_0_params(
zend_function *fn, zend_object *object, zval *retval_ptr);
void zend_call_known_instance_method_with_1_params(
zend_function *fn, zend_object *object, zval *retval_ptr, zval *param);
void zend_call_known_instance_method_with_2_params(
zend_function *fn, zend_object *object, zval *retval_ptr, zval *param1, zval *param2);

These are used to perform a call if you already have the
zend_function you want to call. zend_call_known_function()
is the base API, the rest are just really thin wrappers around
it for the common case of instance method calls.

Closes GH-5692.

show more ...

# be540b35 09-Jun-2020 Nikita Popov

Remove some special-casing in zend_call_method()

Don't treat the !fn_proxy && !obj_ce case differently. There doesn't
seem to be any need for it, and it will result in subtly different

Remove some special-casing in zend_call_method()

Don't treat the !fn_proxy && !obj_ce case differently. There doesn't
seem to be any need for it, and it will result in subtly different
behavior (e.g. it will accept "Foo::bar" syntax, but break as soon
as you pass in an fn_proxy cache).

show more ...

# 33c3691c 25-Apr-2020 Máté Kocsis

Generate method entries from stubs for Zend classes

Closes GH-5459

12345678