Skip to content

Fix voice packet spam and very FPS drop#5066

Open
MoriskaSosiska wants to merge 6 commits into
multitheftauto:masterfrom
MoriskaSosiska:fix_voice_spam
Open

Fix voice packet spam and very FPS drop#5066
MoriskaSosiska wants to merge 6 commits into
multitheftauto:masterfrom
MoriskaSosiska:fix_voice_spam

Conversation

@MoriskaSosiska

@MoriskaSosiska MoriskaSosiska commented Jul 19, 2026

Copy link
Copy Markdown

Hello again!

You may choose not to pay attention to my PR, but I'd really appreciate it if you could review it because it fixes a vulnerability in the MTA client.

This fix addresses the FPS drops (up to the point where the client freezes) that occur when cheaters spam voice chat packets, causing nearby players' games to freeze or stutter due to BASS_StreamPutData slowing down execution.

I moved the 100 ms cooldown check from the client, made a few adjustments to CVoiceDataPacket, and added a check for the return value of speex_decode_int.

I also removed the reserve call and the CVoiceDataPacket constructor so that memory is only allocated if the 100 ms interval has elapsed.

This vulnerability has already been exploited by cheaters on NEXTRP and other projects, as I was told.

Thanks for taking the time to read this!😄

@DateFTP

DateFTP commented Jul 19, 2026

Copy link
Copy Markdown

I'll keep that in mind, as cheaters have already touched my project.

@DateFTP

DateFTP commented Jul 19, 2026

Copy link
Copy Markdown

Thank you for the fix, and we'll be waiting for the review.

@MoriskaSosiska MoriskaSosiska changed the title Fix voice packet spam and FPS drop Fix voice packet spam and very FPS drop Jul 19, 2026
@FileEX FileEX added the bugfix Solution to a bug of any kind label Jul 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bugfix Solution to a bug of any kind

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants