Skip to content

ext/gd: Fix imagewebp() return value for palette images - #24460

Closed
arshidkv12 wants to merge 7706 commits into
php:PHP-8.4from
arshidkv12:gd-gdImageTrueColor
Closed

arshidkv12 wants to merge 7706 commits into
php:PHP-8.4from
arshidkv12:gd-gdImageTrueColor

Conversation

@arshidkv12

Copy link
Copy Markdown
Contributor

alexandre-daubois and others added 30 commits October 12, 2026 09:38
* PHP-8.4:
  Backport PCRE2 security fixes to bundled 10.40
* PHP-8.5:
  Backport PCRE2 security fixes to bundled 10.40
* PHP-8.6:
  Backport PCRE2 security fixes to bundled 10.40
Since 86b4921, php_session_save_current_state() returns without calling
the save handler's close callback when the serializer returns NULL, e.g. for
a $_SESSION key containing '|'. session_write_close() still returns true, but
the files handler keeps its LOCK_EX on the session file until request
shutdown, blocking concurrent requests for the same session, and a user
handler extending SessionHandler has its close() run at shutdown after the
session is gone. Close the handler on that return as the rest of the function
and session_regenerate_id() do; with an exception pending the engine already
refuses to call a user close() callback.

Closes phpGH-24022
* PHP-8.6:
  ext/session: Close save handler when session encoding fails
Rather than resolving trampolines at every call we can simplify increase the refcount for the FCC.
* PHP-8.4:
  Fix skipped catch block when switching fibers during exception unwinding (php#24117)
* PHP-8.5:
  Fix skipped catch block when switching fibers during exception unwinding (php#24117)
* PHP-8.6:
  Fix skipped catch block when switching fibers during exception unwinding (php#24117)
* PHP-8.4:
  ext/readline: Fix non-ASCII completion append characters in readline_info() (php#24263)
* PHP-8.5:
  ext/readline: Fix non-ASCII completion append characters in readline_info() (php#24263)
* PHP-8.6:
  ext/readline: Fix non-ASCII completion append characters in readline_info() (php#24263)
* PHP-8.4:
  Fix escape analysis for objects implementing ArrayAccess
* PHP-8.5:
  Fix escape analysis for objects implementing ArrayAccess
* PHP-8.6:
  Fix escape analysis for objects implementing ArrayAccess
* PHP-8.4:
  Fix phpGH-24260: querySelectorAll() returns duplicate elements for selector lists
* PHP-8.5:
  Fix phpGH-24260: querySelectorAll() returns duplicate elements for selector lists
* PHP-8.6:
  Fix phpGH-24260: querySelectorAll() returns duplicate elements for selector lists
This removes some unused functions/macros in the code base,
* PHP-8.4:
  Fix phpGH-24289: finfo::file() reports the wrong argument number
* PHP-8.5:
  Fix phpGH-24289: finfo::file() reports the wrong argument number
* PHP-8.6:
  Fix phpGH-24289: finfo::file() reports the wrong argument number
zend_jit_init_static_method_call() computes the called scope for a
self:: or parent:: call from a non-static closure as a PHI of
Z_OBJCE(EX(This)) and Z_CE(EX(This)), but discarded the PHI instead of
assigning it to scope_ref. The callee then ran with the resolved class
as called scope, so static::class and new static() returned Base
instead of the forwarded Child (or failed with "Cannot instantiate
abstract class"). Affects function and tracing JIT.

Introduced by 972d6b6 (Fix JIT for INIT_STATIC_METHOD_CALL in a
closure).

Closes phpGH-24287.
* PHP-8.5:
  Fix phpGH-24270: JIT loses called scope of self::/parent:: in closures
LamentXU123 and others added 6 commits October 20, 2026 08:33
* PHP-8.6:
  Backport CI: Fix gh20532.phpt on FreeBSD (php#24424)
* PHP-8.6:
  ext/uri: Refactors builder error handling (php#23834)
* PHP-8.4:
  ext/pdo: Validate Oracle null handling modes
* PHP-8.5:
  ext/pdo: Validate Oracle null handling modes
* PHP-8.6:
  ext/pdo: Validate Oracle null handling modes
NickSdot and others added 6 commits October 20, 2026 14:09
Fix Uri\WhatWg\UrlBuilder's query and fragment handling to be in line with the behavior of the WHATWG URL setter algorithms: Empty strings now remove the corresponding component instead of creating an empty one, both with and without a base URL. An empty component can still be created by passing "?" or "#".
* PHP-8.6:
  ext/uri: Fixes url delimiters (php#23815)
* PHP-8.4:
  JIT: Fix OP_DATA read from an unwritten slot in zend_jit_assign_dim_op()
* PHP-8.5:
  JIT: Fix OP_DATA read from an unwritten slot in zend_jit_assign_dim_op()
* PHP-8.6:
  JIT: Fix OP_DATA read from an unwritten slot in zend_jit_assign_dim_op()
ext/gd: Fix imagewebp() return value for palette images

ext/gd: Fix imagewebp() return value for palette images
arnaud-lb and others added 9 commits October 20, 2026 18:18
* PHP-8.4:
  Make usleep() and time_nanosleep() alertable on Windows (php#24399)
* PHP-8.5:
  Make usleep() and time_nanosleep() alertable on Windows (php#24399)
* PHP-8.6:
  Make usleep() and time_nanosleep() alertable on Windows (php#24399)
…hp#24435)

* Zend: always populate error pointer on failure

Most of the code base expects an error to be set if a char* is provided, as this used to be always the case. It no longer was the case since the partially supported callables were deprecates as the deprecation could be promoted to an exception in which case we skipped allocating a char*.

The simple fix, allocate a char* even in case of an exception so callers don't need to check if it still NULL. This fixes some error messages at the same time.

* tree: simplify error handling for failed zend_is_callable() calls

* docs: clarify docs for zend_is_callable()

---------

Co-authored-by: Arnaud Le Blanc <365207+arnaud-lb@users.noreply.github.com>
…24422)

Since PHP 8.5, glob() uses the bundled implementation on all platforms.
It only recognizes a leading "!" as bracket negation, so patterns such as
"[^a]" match "^" or "a" instead of excluding "a", unlike glibc's glob().

Treat a leading "^" like "!", matching glibc and PHP's fnmatch() behavior,
including on Windows. POSIX leaves this syntax unspecified. Document the
intentional deviation from OpenBSD so it is preserved during future syncs.

Add regression coverage for negated characters and ranges, a leading "]",
and a literal "^" elsewhere in a bracket expression. This was found while
working on symfony/symfony#67133.

Closes php#24422
* PHP-8.5:
  Fix glob() not negating bracket expressions that start with "^" (php#24422)
* PHP-8.6:
  Merge branch 'PHP-8.5' into PHP-8.6
@arshidkv12
arshidkv12 changed the base branch from master to PHP-8.4 October 20, 2026 18:15
@arshidkv12
arshidkv12 changed the base branch from PHP-8.4 to master October 20, 2026 18:19
@arshidkv12
arshidkv12 changed the base branch from master to PHP-8.4 October 20, 2026 18:27
@arshidkv12 arshidkv12 closed this Oct 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.