diff mbox series

[FFmpeg-devel,2/2] avcodec/roqvideodec: Remove set-but-unused frame stats

Message ID 20200830123924.667-2-andreas.rheinhardt@gmail.com
State Accepted
Commit e6c5102fb472395681e227759caae05c5541bcf9
Headers show
Series [FFmpeg-devel,1/2] avcodec/roqvideodec: Move transient GetByteContext to the stack | expand

Checks

Context Check Description
andriy/default pending
andriy/make success Make finished
andriy/make_fate success Make fate finished

Commit Message

Andreas Rheinhardt Aug. 30, 2020, 12:39 p.m. UTC
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
---
Stange that compilers didn't warn about this. Probably because it is an
array.

 libavcodec/roqvideodec.c | 3 ---
 1 file changed, 3 deletions(-)

Comments

Paul B Mahol Aug. 30, 2020, 3:25 p.m. UTC | #1
On 8/30/20, Andreas Rheinhardt <andreas.rheinhardt@gmail.com> wrote:
> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
> ---
> Stange that compilers didn't warn about this. Probably because it is an
> array.
>

probably ok

>  libavcodec/roqvideodec.c | 3 ---
>  1 file changed, 3 deletions(-)
>
> diff --git a/libavcodec/roqvideodec.c b/libavcodec/roqvideodec.c
> index 93c6e9ddf3..36b4ddf755 100644
> --- a/libavcodec/roqvideodec.c
> +++ b/libavcodec/roqvideodec.c
> @@ -39,7 +39,6 @@ static void roqvideo_decode_frame(RoqContext *ri,
> GetByteContext *gb)
>      unsigned long chunk_size = 0;
>      int i, j, k, nv1, nv2, vqflg = 0, vqflg_pos = -1;
>      int vqid, xpos, ypos, xp, yp, x, y, mx, my;
> -    int frame_stats[2][4] = {{0},{0}};
>      roq_qcell *qcell;
>      int64_t chunk_start;
>
> @@ -89,7 +88,6 @@ static void roqvideo_decode_frame(RoqContext *ri,
> GetByteContext *gb)
>                      vqflg_pos = 7;
>                  }
>                  vqid = (vqflg >> (vqflg_pos * 2)) & 0x3;
> -                frame_stats[0][vqid]++;
>                  vqflg_pos--;
>
>                  switch(vqid) {
> @@ -124,7 +122,6 @@ static void roqvideo_decode_frame(RoqContext *ri,
> GetByteContext *gb)
>                              vqflg_pos = 7;
>                          }
>                          vqid = (vqflg >> (vqflg_pos * 2)) & 0x3;
> -                        frame_stats[1][vqid]++;
>                          vqflg_pos--;
>                          switch(vqid) {
>                          case RoQ_ID_MOT:
> --
> 2.20.1
>
> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel@ffmpeg.org
> https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
>
> To unsubscribe, visit link above, or email
> ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
diff mbox series

Patch

diff --git a/libavcodec/roqvideodec.c b/libavcodec/roqvideodec.c
index 93c6e9ddf3..36b4ddf755 100644
--- a/libavcodec/roqvideodec.c
+++ b/libavcodec/roqvideodec.c
@@ -39,7 +39,6 @@  static void roqvideo_decode_frame(RoqContext *ri, GetByteContext *gb)
     unsigned long chunk_size = 0;
     int i, j, k, nv1, nv2, vqflg = 0, vqflg_pos = -1;
     int vqid, xpos, ypos, xp, yp, x, y, mx, my;
-    int frame_stats[2][4] = {{0},{0}};
     roq_qcell *qcell;
     int64_t chunk_start;
 
@@ -89,7 +88,6 @@  static void roqvideo_decode_frame(RoqContext *ri, GetByteContext *gb)
                     vqflg_pos = 7;
                 }
                 vqid = (vqflg >> (vqflg_pos * 2)) & 0x3;
-                frame_stats[0][vqid]++;
                 vqflg_pos--;
 
                 switch(vqid) {
@@ -124,7 +122,6 @@  static void roqvideo_decode_frame(RoqContext *ri, GetByteContext *gb)
                             vqflg_pos = 7;
                         }
                         vqid = (vqflg >> (vqflg_pos * 2)) & 0x3;
-                        frame_stats[1][vqid]++;
                         vqflg_pos--;
                         switch(vqid) {
                         case RoQ_ID_MOT: