diff mbox series

[FFmpeg-devel] avcodec/mlpenc: Fix mixed declarations and code warning

Message ID AM7PR03MB6660133E77FAA9ED72FB92A98FD49@AM7PR03MB6660.eurprd03.prod.outlook.com
State Accepted
Commit bb9141cc1397960bbc869ac9df3bab15e2dc6458
Headers show
Series [FFmpeg-devel] avcodec/mlpenc: Fix mixed declarations and code warning | expand

Checks

Context Check Description
andriy/make_x86 success Make finished
andriy/make_fate_x86 fail Make fate failed
andriy/make_ppc success Make finished
andriy/make_fate_ppc fail Make fate failed

Commit Message

Andreas Rheinhardt Sept. 8, 2021, 10:02 p.m. UTC
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
---
Will apply this soon.

 libavcodec/mlpenc.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/libavcodec/mlpenc.c b/libavcodec/mlpenc.c
index 6d4a12ce3b..ef01c1d282 100644
--- a/libavcodec/mlpenc.c
+++ b/libavcodec/mlpenc.c
@@ -476,6 +476,7 @@  static av_cold int mlp_encode_init(AVCodecContext *avctx)
 {
     static AVOnce init_static_once = AV_ONCE_INIT;
     MLPEncodeContext *ctx = avctx->priv_data;
+    RestartHeader *const rh = &ctx->restart_header;
     unsigned int sum = 0;
     size_t size;
     int ret;
@@ -674,8 +675,6 @@  static av_cold int mlp_encode_init(AVCodecContext *avctx)
     if (!ctx->decoding_params)
         return AVERROR(ENOMEM);
 
-    RestartHeader  *rh = &ctx->restart_header;
-
     /* TODO see if noisegen_seed is really worth it. */
     rh->noisegen_seed      = 0;