From 892855f399687bf0060a815d59a5dc21eba282a0 Mon Sep 17 00:00:00 2001 From: Daniil Gentili Date: Tue, 29 Aug 2023 10:05:58 +0200 Subject: [PATCH] Avoid integer overflow --- docs | 2 +- src/VoIP/MessageHandler.php | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/docs b/docs index 4b1bbd681..9d0080f34 160000 --- a/docs +++ b/docs @@ -1 +1 @@ -Subproject commit 4b1bbd6817f08e10a68105fa226e646c1b89aa1a +Subproject commit 9d0080f3478c816d52dae55ee2c7dc6ab13d63f7 diff --git a/src/VoIP/MessageHandler.php b/src/VoIP/MessageHandler.php index 406d5c839..0244d9765 100644 --- a/src/VoIP/MessageHandler.php +++ b/src/VoIP/MessageHandler.php @@ -238,6 +238,7 @@ final class MessageHandler return false; } $this->acksForReceived |= 1 << ($diff+1); + $this->acksForReceived &= 0xFFFF_FFFF; } else { Logger::log("Packet $packet_seq_no is out of order and too late"); return false;