Skip to content

fix(timeout): drive the inner awaitable's full awaiter protocol#329

Merged
sgerbino merged 1 commit into
cppalliance:developfrom
sgerbino:fix/timeout-awaiter-protocol
Jul 25, 2026
Merged

fix(timeout): drive the inner awaitable's full awaiter protocol#329
sgerbino merged 1 commit into
cppalliance:developfrom
sgerbino:fix/timeout-awaiter-protocol

Conversation

@sgerbino

Copy link
Copy Markdown
Collaborator

timeout_awaitable::await_suspend called straight into the inner awaitable's await_suspend without first calling its await_ready. Awaitables that perform setup in await_ready — type-erased stream wrappers construct their cached inner op there — were driven against unconstructed storage, yielding garbage reads or a segfault.

Forward await_ready to the inner awaitable so the full protocol reaches it. An already-ready inner op now also completes without suspending or arming the deadline timer.

Resolves #327.

timeout_awaitable::await_suspend called straight into the inner
awaitable's await_suspend without first calling its await_ready.
Awaitables that perform setup in await_ready — type-erased stream
wrappers construct their cached inner op there — were driven against
unconstructed storage, yielding garbage reads or a segfault.

Forward await_ready to the inner awaitable so the full protocol
reaches it. An already-ready inner op now also completes without
suspending or arming the deadline timer.
@cppalliance-bot

Copy link
Copy Markdown

An automated preview of the documentation is available at https://329.corosio.prtest3.cppalliance.org/index.html

If more commits are pushed to the pull request, the docs will rebuild at the same URL.

2026-07-24 21:49:35 UTC

@cppalliance-bot

Copy link
Copy Markdown

GCOVR code coverage report https://329.corosio.prtest3.cppalliance.org/gcovr/index.html
LCOV code coverage report https://329.corosio.prtest3.cppalliance.org/genhtml/index.html
Coverage Diff Report https://329.corosio.prtest3.cppalliance.org/diff-report/index.html

Build time: 2026-07-24 22:00:01 UTC

@codecov

codecov Bot commented Jul 25, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 77.47%. Comparing base (953f592) to head (2ea858c).
⚠️ Report is 3 commits behind head on develop.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff            @@
##           develop     #329   +/-   ##
========================================
  Coverage    77.47%   77.47%           
========================================
  Files           96       96           
  Lines         6868     6868           
  Branches      1652     1652           
========================================
  Hits          5321     5321           
  Misses        1055     1055           
  Partials       492      492           

Continue to review full report in Codecov by Harness.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 953f592...2ea858c. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@sgerbino
sgerbino merged commit 31a078b into cppalliance:develop Jul 25, 2026
44 checks passed
@sgerbino
sgerbino deleted the fix/timeout-awaiter-protocol branch July 25, 2026 02:01
@github-project-automation github-project-automation Bot moved this from Backlog to Done in Beast2 Jul 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

wrapping async_read_some() in a timeout() causes segfault

2 participants