[FFmpeg-devel] [PATCH] avformat/hcom: Remove unused variables

Andreas Rheinhardt andreas.rheinhardt at gmail.com
Mon May 13 22:31:19 EEST 2019


The variables huffcount, rsrc_size and data_size were all set but not
used. Therefore they have been removed.
This fixes -Wunused-but-set-variable warnings in GCC.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at gmail.com>
---
 libavformat/hcom.c | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/libavformat/hcom.c b/libavformat/hcom.c
index 0d1736b620..98ed66f4f2 100644
--- a/libavformat/hcom.c
+++ b/libavformat/hcom.c
@@ -38,16 +38,15 @@ static int hcom_probe(const AVProbeData *p)
 static int hcom_read_header(AVFormatContext *s)
 {
     AVStream *st;
-    unsigned data_size, rsrc_size, huffcount;
     unsigned compresstype, divisor;
     unsigned dict_entries;
     int ret;
 
     avio_skip(s->pb, 83);
-    data_size = avio_rb32(s->pb);
-    rsrc_size = avio_rb32(s->pb);
+    avio_rb32(s->pb); /* data_size */
+    avio_rb32(s->pb); /* rsrc_size */
     avio_skip(s->pb, 128-91+4);
-    huffcount = avio_rb32(s->pb);
+    avio_rb32(s->pb); /* huffcount */
     avio_skip(s->pb, 4);
     compresstype = avio_rb32(s->pb);
     if (compresstype > 1)
-- 
2.21.0



More information about the ffmpeg-devel mailing list