mirror of
https://github.com/Divested-Mobile/DivestOS-Build.git
synced 2024-12-14 10:24:32 -05:00
59bf3b75c7
https://review.lineageos.org/c/LineageOS/android_frameworks_base/+/353117 https://review.lineageos.org/q/topic:Q_asb_2023-03 https://review.lineageos.org/q/topic:Q_asb_2023-04 https://review.lineageos.org/q/topic:Q_asb_2023-05 https://review.lineageos.org/q/topic:Q_asb_2023-06 https://review.lineageos.org/q/topic:Q_asb_2023-07 https://review.lineageos.org/q/topic:Q_asb_2023-08 accounted for via patches: https://review.lineageos.org/c/LineageOS/android_system_ca-certificates/+/376560 https://review.lineageos.org/c/LineageOS/android_system_ca-certificates/+/376561 https://review.lineageos.org/c/LineageOS/android_system_ca-certificates/+/376562 https://review.lineageos.org/q/topic:Q_asb_2023-09 https://review.lineageos.org/q/topic:Q_asb_2023-10 https://review.lineageos.org/q/topic:Q_asb_2023-11 accounted for via patches: https://review.lineageos.org/c/LineageOS/android_system_ca-certificates/+/376563 accounted for via manifest change: https://review.lineageos.org/c/LineageOS/android_external_webp/+/376568 https://review.lineageos.org/q/topic:Q_asb_2023-12 https://review.lineageos.org/q/topic:Q_asb_2024-01 https://review.lineageos.org/q/topic:Q_asb_2024-02 https://review.lineageos.org/q/topic:Q_asb_2024-03 Signed-off-by: Tavi <tavi@divested.dev>
35 lines
1.5 KiB
Diff
35 lines
1.5 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Haripriya Deshmukh <haripriya.deshmukh@ittiam.com>
|
|
Date: Tue, 5 Dec 2023 18:32:38 +0000
|
|
Subject: [PATCH] Fix out of bounds read and write in onQueueFilled in outQueue
|
|
|
|
Bug: 276442130
|
|
Test: POC in bug descriptions
|
|
(cherry picked from https://partner-android-review.googlesource.com/q/commit:7aef41e59412e2f95bab5de7e33f5f04bb808643)
|
|
(cherry picked from commit 8f4cfda9fc75f1e9ba3b6dee3fbffda4b6111d64)
|
|
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:208e430bc6380fafafca8041b239f835263a9d47)
|
|
Merged-In: Ic230d10048193a785f185dc6a7de6f455f9318c1
|
|
Change-Id: Ic230d10048193a785f185dc6a7de6f455f9318c1
|
|
---
|
|
media/libstagefright/codecs/m4v_h263/dec/SoftMPEG4.cpp | 7 +++++--
|
|
1 file changed, 5 insertions(+), 2 deletions(-)
|
|
|
|
diff --git a/media/libstagefright/codecs/m4v_h263/dec/SoftMPEG4.cpp b/media/libstagefright/codecs/m4v_h263/dec/SoftMPEG4.cpp
|
|
index 60750d9a61..db08030ad1 100644
|
|
--- a/media/libstagefright/codecs/m4v_h263/dec/SoftMPEG4.cpp
|
|
+++ b/media/libstagefright/codecs/m4v_h263/dec/SoftMPEG4.cpp
|
|
@@ -312,8 +312,11 @@ void SoftMPEG4::onQueueFilled(OMX_U32 /* portIndex */) {
|
|
outHeader->nFilledLen = frameSize;
|
|
|
|
List<BufferInfo *>::iterator it = outQueue.begin();
|
|
- while ((*it)->mHeader != outHeader) {
|
|
- ++it;
|
|
+ while (it != outQueue.end() && (*it)->mHeader != outHeader) {
|
|
+ ++it;
|
|
+ }
|
|
+ if (it == outQueue.end()) {
|
|
+ return;
|
|
}
|
|
|
|
BufferInfo *outInfo = *it;
|