Skip to content
Snippets Groups Projects

Fix buffer overflow in setcontrol with 2 arguments

Merged Hanicef requested to merge Hanicef/SRB2Classic:setcontrol-buffer-overflow into next

While debugging another issue, I noticed that MemorySanitizer was firing off a buffer overflow error when the game launched. Turns out that there was a missing COM_Argc check in setcontrol, which caused it to try to get the third argument regardless if it was specified or not. This bug doesn't seem to impact anything in practice, but since MemorySanitizer is designed to detect bugs like this, I thought it'd be better just to send in a fix than to just ignore it.

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Loading
  • Loading
Please register or sign in to reply
Loading