Skip to content

engine: fix up NET_FindOrCreateSplitPacketEntry#171

Merged
dimhotepus merged 1 commit intoSource-Authors:masterfrom
RaphaelIT7:rmod-patch-8
Feb 8, 2026
Merged

engine: fix up NET_FindOrCreateSplitPacketEntry#171
dimhotepus merged 1 commit intoSource-Authors:masterfrom
RaphaelIT7:rmod-patch-8

Conversation

@RaphaelIT7
Copy link
Contributor

@RaphaelIT7 RaphaelIT7 commented Feb 3, 2026

Fixing it

With the commit c07099f the function NET_FindOrCreateSplitPacketEntry was changed and broken.

entry was never set to a valid value, causing the entire function to basically fail to "Find" a split packet entry.

Improving it

I've made a small improvement to use splitPacketEntries.AddToTailGetPtr(); which avoids stack allocating CSplitPacketEntry temporarily just to allocate it into the vector anyways- avoiding a possible stack overflow if, for example, some net limits were raised & it became too big.

Small assert

I've added a small assert to NET_GetLong as currently in one of my builds I'm getting some corrupted packet numbers and crashes.
This is simply to make debugging such things a bit easier.
This issue is fixed by #172

dimhotepus added a commit that referenced this pull request Feb 8, 2026
@RaphaelIT7
Copy link
Contributor Author

With NET_FindOrCreateSplitPacketEntry having been fixed this now only contains the improvement ^^

@dimhotepus dimhotepus merged commit bb1c7c7 into Source-Authors:master Feb 8, 2026
0 of 20 checks passed
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