Skip to content

Fix stack overflow on sending UDP packets#9381

Merged
maskit merged 1 commit intoapache:masterfrom
maskit:fix_quic_stack_overflow
Feb 7, 2023
Merged

Fix stack overflow on sending UDP packets#9381
maskit merged 1 commit intoapache:masterfrom
maskit:fix_quic_stack_overflow

Conversation

@maskit
Copy link
Member

@maskit maskit commented Feb 3, 2023

The check is simply wrong. It has to break out from the loop if npackets reaches the limit.

@maskit maskit added this to the 10.0.0 milestone Feb 3, 2023
@maskit maskit self-assigned this Feb 3, 2023
@bryancall bryancall self-requested a review February 7, 2023 00:07
packets[npackets++] = p;
next_pkt:
if (bytesThisPipe < 0 && npackets == N_MAX_PACKETS) {
if (bytesThisPipe < 0 || npackets == N_MAX_PACKETS) {
Copy link
Contributor

Choose a reason for hiding this comment

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

= seems safer, but it really shouldn't matter

@maskit maskit merged commit f099a59 into apache:master Feb 7, 2023
moleksy pushed a commit to moleksy/trafficserver that referenced this pull request Feb 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants