diff mbox series

[FFmpeg-devel,2/3] avformat/rcwtenc: Remove redundant zeroing of buffer

Message ID AS8P250MB074462C0CACA87A37EFEEFE58F442@AS8P250MB0744.EURP250.PROD.OUTLOOK.COM
State Accepted
Commit a8e55cf11846c4e44d45985dd0a8a5a53e2359aa
Headers show
Series [FFmpeg-devel,1/3] avformat/rcwtenc: Fix potential out-of-bounds write | expand

Checks

Context Check Description
yinshiyou/make_loongarch64 success Make finished
yinshiyou/make_fate_loongarch64 success Make fate finished
andriy/make_x86 success Make finished
andriy/make_fate_x86 success Make fate finished

Commit Message

Andreas Rheinhardt Feb. 8, 2024, 3:09 p.m. UTC
Resetting the counter of used elements is enough as nothing is
ever read from the currently unused elements.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
---
 libavformat/rcwtenc.c | 1 -
 1 file changed, 1 deletion(-)
diff mbox series

Patch

diff --git a/libavformat/rcwtenc.c b/libavformat/rcwtenc.c
index d0e469ce65..084de6e205 100644
--- a/libavformat/rcwtenc.c
+++ b/libavformat/rcwtenc.c
@@ -76,7 +76,6 @@  static void rcwt_init_cluster(AVFormatContext *avf)
 
     rcwt->cluster_pos = 0;
     rcwt->cluster_pts = AV_NOPTS_VALUE;
-    memset(rcwt->cluster_buf, 0, sizeof(rcwt->cluster_buf));
 }
 
 static void rcwt_flush_cluster(AVFormatContext *avf)