Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[core/cyclicbuffer] : Cherry pick from 'db117dcbe2ef7d01e80b8aacaff2a……db64c7da8ed' #1560

Merged
merged 9 commits into from
Jun 13, 2024

Conversation

msieben
Copy link
Contributor

@msieben msieben commented Apr 4, 2024

Assert on overflow in 'GetCompleteTail'.

An (unlikely) overflow can occur if 'size' is set to its maximum value. Then, all bits in the 'mask' become set.

…db64c7da8ed'

Assert on overflow in 'GetCompleteTail'.
@msieben msieben requested review from pwielders and MFransen69 April 4, 2024 13:06
@msieben msieben requested a review from VeithMetro May 23, 2024 14:40
Copy link
Contributor

@VeithMetro VeithMetro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed that this ASSERT could be here just to be sure we won't be diving by zero soon after.

Source/core/CyclicBuffer.h Outdated Show resolved Hide resolved
@msieben msieben force-pushed the development/cyclicbuffer-overflow-tail-calculation branch from b8e1e27 to 5a206f7 Compare May 24, 2024 07:35
@VeithMetro VeithMetro self-requested a review May 24, 2024 08:35
@msieben msieben merged commit 6924ac4 into master Jun 13, 2024
16 of 26 checks passed
@pwielders pwielders deleted the development/cyclicbuffer-overflow-tail-calculation branch October 11, 2024 18:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants