[FFmpeg-cvslog] avcodec/ituh263dec: Use stack variable for aspect_ratio_info
Andreas Rheinhardt
git at videolan.org
Sat Jan 29 21:02:32 EET 2022
ffmpeg | branch: master | Andreas Rheinhardt <andreas.rheinhardt at outlook.com> | Tue Jan 25 13:24:13 2022 +0100| [9288b6366b5f917ea80415bf48c6a0f621189ec0] | committer: Andreas Rheinhardt
avcodec/ituh263dec: Use stack variable for aspect_ratio_info
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at outlook.com>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=9288b6366b5f917ea80415bf48c6a0f621189ec0
---
libavcodec/ituh263dec.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/libavcodec/ituh263dec.c b/libavcodec/ituh263dec.c
index 0a032ea54c..7d7a1f01a2 100644
--- a/libavcodec/ituh263dec.c
+++ b/libavcodec/ituh263dec.c
@@ -1222,8 +1222,8 @@ int ff_h263_decode_picture_header(MpegEncContext *s)
if (ufep) {
if (format == 6) {
/* Custom Picture Format (CPFMT) */
- s->aspect_ratio_info = get_bits(&s->gb, 4);
- ff_dlog(s->avctx, "aspect: %d\n", s->aspect_ratio_info);
+ int aspect_ratio_info = get_bits(&s->gb, 4);
+ ff_dlog(s->avctx, "aspect: %d\n", aspect_ratio_info);
/* aspect ratios:
0 - forbidden
1 - 1:1
@@ -1237,12 +1237,12 @@ int ff_h263_decode_picture_header(MpegEncContext *s)
check_marker(s->avctx, &s->gb, "in dimensions");
height = get_bits(&s->gb, 9) * 4;
ff_dlog(s->avctx, "\nH.263+ Custom picture: %dx%d\n",width,height);
- if (s->aspect_ratio_info == FF_ASPECT_EXTENDED) {
+ if (aspect_ratio_info == FF_ASPECT_EXTENDED) {
/* expected dimensions */
s->avctx->sample_aspect_ratio.num= get_bits(&s->gb, 8);
s->avctx->sample_aspect_ratio.den= get_bits(&s->gb, 8);
}else{
- s->avctx->sample_aspect_ratio= ff_h263_pixel_aspect[s->aspect_ratio_info];
+ s->avctx->sample_aspect_ratio= ff_h263_pixel_aspect[aspect_ratio_info];
}
} else {
width = ff_h263_format[format][0];
More information about the ffmpeg-cvslog
mailing list