Commit graph

134175 commits

Author SHA1 Message Date
Jakub Zelenka
500b0fee40
Merge branch 'PHP-8.3' 2023-11-17 19:44:45 +00:00
Jakub Zelenka
b3947744c7
Merge branch 'PHP-8.2' into PHP-8.3 2023-11-17 19:43:34 +00:00
Jakub Zelenka
f90b40416f
Fix #50713: openssl_pkcs7_verify() may ignore untrusted CAs
Closes GH-12499
2023-11-17 19:42:28 +00:00
Niels Dossche
6f215e0727 Merge branch 'PHP-8.3'
* PHP-8.3:
  Fix GH-12616: DOM: Removing XMLNS namespace node results in invalid default: prefix
  Fix GH-12702: libxml2 2.12.0 issue building from src
2023-11-17 19:58:57 +01:00
Niels Dossche
2b42b73c0b Merge branch 'PHP-8.2' into PHP-8.3
* PHP-8.2:
  Fix GH-12616: DOM: Removing XMLNS namespace node results in invalid default: prefix
  Fix GH-12702: libxml2 2.12.0 issue building from src
2023-11-17 19:58:31 +01:00
Niels Dossche
3167d07603 Fix GH-12616: DOM: Removing XMLNS namespace node results in invalid default: prefix
The namespace data is freed and set to NULL, but there remain references
to the namespace declaration nodes. This (rightfully) confuses libxml2
because its invariants are broken. We also have to remove all remaining
references from the subtree. This fixes the data corruption bug.

Closes GH-12681.
2023-11-17 19:47:08 +01:00
Niels Dossche
8a95e616b9 Fix GH-12702: libxml2 2.12.0 issue building from src
Fixes GH-12702.

Co-authored-by: nono303 <github@nono303.net>
2023-11-17 19:46:30 +01:00
Niels Dossche
7658220599
Improve performance of mbfl_name2encoding() by using perfect hashing (#12707)
mbfl_name2encoding() uses a linear loop through the encodings, comparing
the name one by one, which is very slow. For the benchmark [1] just
looking up the name takes about 50% of run-time.

By using perfect hashing instead, we no longer have to loop over the
list, and the number of string comparisons is reduced to just a single
one. The perfect hashing table is generated using GNU gperf and amended
manually to fit in with mbstring and manually changed to  reduce the
cache size.

[1] https://github.com/php/php-src/issues/12684#issuecomment-1813799924
2023-11-17 19:38:43 +01:00
David CARLIER
931a8b0739
inet_ntop requirement check at configure time instead (#12700) 2023-11-17 16:01:46 +00:00
KentarouTakeda
7f7da6aef9
Enable pdo-firebird nightly testing (#12699)
* Enable `pdo-firebird` Testing in Nightly

* fix(ext/pdo_firebird/tests): dont detect memory leak

* fix(ext/pdo_firebird): memory alignment error
2023-11-17 15:25:44 +01:00
Jakub Zelenka
62b2ad4b8a
Merge branch 'PHP-8.3' 2023-11-17 13:42:59 +00:00
Jakub Zelenka
7abe3fe4c6
Merge branch 'PHP-8.2' into PHP-8.3 2023-11-17 13:41:50 +00:00
Jakub Zelenka
4da89d86ec
Fix stream fclose_stdiocast_flush_in_progress type 2023-11-17 13:33:55 +00:00
Jakub Zelenka
6734880ef5
Fix bug #79945: Stream wrappers in imagecreatefrompng causes segfault
Closes GH-12696
2023-11-17 13:26:42 +00:00
Ilija Tovilo
c442a1f18e
Temporarily disable failing zlib tests on travis (#10738) 2023-11-17 13:24:20 +00:00
Jakub Zelenka
d75240634d
Merge branch 'PHP-8.3' 2023-11-17 12:46:30 +00:00
Jakub Zelenka
59dcb0065d
Revert "Temporarily disable failing zlib tests on travis (#10738)"
This reverts commit 8c9c6787cc.
2023-11-17 12:45:09 +00:00
Jakub Zelenka
21596bfeb9
Merge branch 'PHP-8.3' 2023-11-17 12:11:54 +00:00
Jakub Zelenka
53371b7f89
Merge branch 'PHP-8.2' into PHP-8.3 2023-11-17 12:11:32 +00:00
Jakub Zelenka
708e9fadfd
Skip slow tests on Travis
Closes GH-12697
2023-11-17 12:10:14 +00:00
Jakub Zelenka
0f349d4c24
Add POSIX_SC_CHILD_MAX and POSIX_SC_CLK_TCK constants
Closes GH-12689
2023-11-17 11:09:30 +00:00
Alexandre Daubois
6f95273941
ext/pdo_mysql: Improve tests cleanup (#11879)
This allows the tests to be run in parallel.
2023-11-16 18:49:43 +00:00
Ilija Tovilo
44467eb29b
[skip ci] Update libmysqlclient versions
5.7 is EOL, 8.2 was released. Also remove mysqli from these builds as PHP-8.1
goes into security mode, after which nightly is not really actively supported
anymore.

Closes GH-12690
2023-11-16 17:02:35 +01:00
Ilija Tovilo
02494e7657
Merge branch 'PHP-8.3'
* PHP-8.3:
  [skip ci] Fix more test tmp file conflicts
2023-11-16 16:28:46 +01:00
Ilija Tovilo
8828d6ac1d
Merge branch 'PHP-8.2' into PHP-8.3
* PHP-8.2:
  [skip ci] Fix more test tmp file conflicts
2023-11-16 16:28:40 +01:00
Ilija Tovilo
d5c6633bd1
[skip ci] Fix more test tmp file conflicts 2023-11-16 16:28:12 +01:00
Ilija Tovilo
52535ba08c
Merge branch 'PHP-8.3'
* PHP-8.3:
  Retry tests on deadlock
2023-11-16 16:03:08 +01:00
Ilija Tovilo
ed927365c2
Merge branch 'PHP-8.2' into PHP-8.3
* PHP-8.2:
  Retry tests on deadlock
2023-11-16 16:02:58 +01:00
Ilija Tovilo
58712e0698
Retry tests on deadlock
Closes GH-12693
2023-11-16 16:02:20 +01:00
Ilija Tovilo
4a06c1d18b
Merge branch 'PHP-8.3'
* PHP-8.3:
  Fix file test race condition
2023-11-16 15:40:48 +01:00
Ilija Tovilo
3060edf6af
Merge branch 'PHP-8.2' into PHP-8.3
* PHP-8.2:
  Fix file test race condition
2023-11-16 15:40:41 +01:00
Ilija Tovilo
a742010a0a
Fix file test race condition
005_variation2.phpt creates files with special names, and
filesize_variation5.phpt checks for filesize of inexistent files with special
names. Create the files in a separate directory to avoid these tests clashing.

Closes GH-12692
2023-11-16 15:40:16 +01:00
Jakub Zelenka
ee56038d38
Merge branch 'PHP-8.3' 2023-11-16 14:37:41 +00:00
Jakub Zelenka
945c512a4e
Merge branch 'PHP-8.2' into PHP-8.3 2023-11-16 14:37:10 +00:00
Jakub Zelenka
bf250e9f88
Merge branch 'PHP-8.1' into PHP-8.2 2023-11-16 14:36:16 +00:00
Jakub Zelenka
b4208c8f96
Initialize syslog device in GINIT
Closes GH-12663
2023-11-16 14:31:44 +00:00
KentarouTakeda
3a544d151c
Enable pdo-firebird Testing in Linux CI Environments (#12677) 2023-11-16 11:52:14 +01:00
Ilija Tovilo
2895d4ac46
[skip ci] Update mysql 8.0 patch 2023-11-16 11:04:42 +01:00
Pengfei Li
f2706a8f30
JIT/AArch64: Fix an undefined symbol issue (#12687)
In AArch64 function `zend_jit_set_veneer()`, some debug code calls two
other functions `ir_disasm_find_symbol()` and `ir_disasm_add_symbol()`
defined in `ir_disasm.c`. However, `ir_disasm.c` is compiled under the
condition that capstone is available. This causes an undefined symbol
issue while loading `opcache.so` when JIT is triggered if PHP is built
without `--with-capstone`.

We find this issue on MacOS 12.5 if we build PHP with Clang 14. It does
not appear immediately when using other versions of toolchains because
of lazy binding. To reproduce this with Linux/GCC, we can disable lazy
binding by `export LD_BIND_NOW=1` before building PHP.

This fixes the issue by making the debug code conditionally compile.
2023-11-16 11:57:09 +03:00
George Peter Banyard
ba204a2e3a
ext/spl: Restructure spl_array.c file to move ArrayObject methods together 2023-11-16 00:41:37 +00:00
Gina Peter Banyard
1bdb0fddc1
Refactor pcntl_sigprocmask()/pcntl_sigwaitinfo()/pcntl_sigtimedwait() (#11860) 2023-11-16 00:40:18 +00:00
Niels Dossche
d882c5d580 Merge branch 'PHP-8.3'
* PHP-8.3:
  Use __DIR__-relative path in tests
  Fix GH-12675: MEMORY_LEAK in phpdbg_prompt.c
2023-11-15 22:01:05 +01:00
Niels Dossche
c83632a503 Merge branch 'PHP-8.2' into PHP-8.3
* PHP-8.2:
  Use __DIR__-relative path in tests
  Fix GH-12675: MEMORY_LEAK in phpdbg_prompt.c
2023-11-15 22:00:44 +01:00
Niels Dossche
f320c3561e Use __DIR__-relative path in tests
Otherwise we can't run them from another directory, they'll fail
instead.
2023-11-15 22:00:04 +01:00
Niels Dossche
4f1103ef3b Fix GH-12675: MEMORY_LEAK in phpdbg_prompt.c
Have to use file_put_contents() instead of --FILE-- because we have to
actually load it using the exec command, *and* have to make multiple
files, and note that we can only load files relative from the current
directory, so we can't rely on files being in the sapi/phpdbg/tests
folder.

Closes GH-12680.
2023-11-15 21:59:55 +01:00
Ilija Tovilo
16f39ec80b
Intercept strlcpy and strlcat for msan on Clang 17 (#12674) 2023-11-15 17:43:44 +01:00
Ilija Tovilo
7bcfac9e65
Merge branch 'PHP-8.3'
* PHP-8.3:
  Automatically mark tests as flaky
2023-11-15 13:22:43 +01:00
Ilija Tovilo
082219ba0e
Merge branch 'PHP-8.2' into PHP-8.3
* PHP-8.2:
  Automatically mark tests as flaky
2023-11-15 13:22:35 +01:00
Ilija Tovilo
6d59640980
Automatically mark tests as flaky
Marking all of these tests as flaky is annoying, so attempt to recognize them
automatically.

Closes GH-12638
2023-11-15 13:21:58 +01:00
Ilija Tovilo
5aeada0ee3
Fix potentially uninitialized warning on release build 2023-11-15 13:14:55 +01:00