• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

krakjoe / parallel / 27614957808
95%

Build:
DEFAULT BRANCH: develop
Ran 16 Jun 2026 11:42AM UTC
Jobs 18
Files 29
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

16 Jun 2026 11:41AM UTC coverage: 95.095% (-0.03%) from 95.123%
27614957808

push

github

web-flow
Fix use-after-free race on future->monitor in error paths (#381)

When a task threw (normal exception) or crashed (IllegalInstruction), the
worker signalled the future twice: first PHP_PARALLEL_ERROR (or READY|ERROR),
then an unconditional trailing PHP_PARALLEL_READY at the end of
php_parallel_scheduler_run().

Future::value() waits on READY|FAILURE|ERROR, so the first signal already
releases the consumer. The consumer can then tear the future down (freeing
future->monitor) before the worker runs the trailing
php_parallel_monitor_set(future->monitor, PHP_PARALLEL_READY), which then
dereferences a dangling monitor inside pthread_cond_signal -> access
violation / use-after-free.

This was observed as a hard crash on Windows (0xC0000005) in
tests/functional/007.phpt, masked until now by the catch-all VEH; on Linux
the freed memory happened to stay readable.

Fix: the error paths now signal READY|ERROR exactly once and skip the
trailing READY (via a 'ready' flag). The success and kill paths are
unchanged - they have no early wake and still rely on the trailing READY.
Setting READY in the error path also ensures the future destructor (which
waits for READY) never blocks when value() is not called.

4 of 5 new or added lines in 1 file covered. (80.0%)

2908 of 3058 relevant lines covered (95.09%)

5512.85 hits per line

Uncovered Changes

Lines Coverage ∆ File
1
85.75
-0.14% src/scheduler.c
Jobs
ID Job ID Ran Files Coverage
1 jit-8.5 - 27614957808.1 16 Jun 2026 11:44AM UTC 54
90.35
GitHub Action Run
2 vanilla-8.2 - 27614957808.2 16 Jun 2026 11:43AM UTC 53
94.41
GitHub Action Run
3 opcache-8.2 - 27614957808.3 16 Jun 2026 11:43AM UTC 53
90.28
GitHub Action Run
4 opcache-8.3 - 27614957808.4 16 Jun 2026 11:42AM UTC 53
90.25
GitHub Action Run
5 opcache-8.1 - 27614957808.5 16 Jun 2026 11:42AM UTC 53
90.16
GitHub Action Run
6 vanilla-8.3 - 27614957808.6 16 Jun 2026 11:43AM UTC 53
94.38
GitHub Action Run
7 vanilla-8.0 - 27614957808.7 16 Jun 2026 11:42AM UTC 54
94.82
GitHub Action Run
8 jit-8.0 - 27614957808.8 16 Jun 2026 11:42AM UTC 54
91.0
GitHub Action Run
9 opcache-8.5 - 27614957808.9 16 Jun 2026 11:44AM UTC 54
90.35
GitHub Action Run
10 jit-8.4 - 27614957808.10 16 Jun 2026 11:42AM UTC 54
90.38
GitHub Action Run
11 opcache-8.0 - 27614957808.11 16 Jun 2026 11:42AM UTC 54
91.0
GitHub Action Run
12 vanilla-8.4 - 27614957808.12 16 Jun 2026 11:44AM UTC 54
94.43
GitHub Action Run
13 jit-8.3 - 27614957808.13 16 Jun 2026 11:42AM UTC 53
90.29
GitHub Action Run
14 vanilla-8.5 - 27614957808.14 16 Jun 2026 11:44AM UTC 54
94.47
GitHub Action Run
15 jit-8.2 - 27614957808.15 16 Jun 2026 11:43AM UTC 53
90.28
GitHub Action Run
16 vanilla-8.1 - 27614957808.16 16 Jun 2026 11:43AM UTC 53
94.26
GitHub Action Run
17 opcache-8.4 - 27614957808.17 16 Jun 2026 11:42AM UTC 54
90.38
GitHub Action Run
18 jit-8.1 - 27614957808.18 16 Jun 2026 11:42AM UTC 53
90.12
GitHub Action Run
Source Files on build 27614957808
  • Tree
  • List 29
  • Changed 8
  • Source Changed 0
  • Coverage Changed 8
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • d0dee716 on github
  • Prev Build on develop (#27606194673)
  • Next Build on develop (#27614970384)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc