[FFmpeg-cvslog] avformat/lrcdec: Fix declaration-after-statement warning

Andreas Rheinhardt git at videolan.org
Sat Jul 29 19:47:33 EEST 2023


ffmpeg | branch: master | Andreas Rheinhardt <andreas.rheinhardt at outlook.com> | Sat Jul 29 17:58:58 2023 +0200| [bf9f6a5e559c901453b484a606e27af54d7e93d5] | committer: Andreas Rheinhardt

avformat/lrcdec: Fix declaration-after-statement warning

Happens since c0f867bf503e79eba8ee52e1ac53322f88ec2929.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at outlook.com>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=bf9f6a5e559c901453b484a606e27af54d7e93d5
---

 libavformat/lrcdec.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/libavformat/lrcdec.c b/libavformat/lrcdec.c
index 83bb4a4b75..f43e9dccf5 100644
--- a/libavformat/lrcdec.c
+++ b/libavformat/lrcdec.c
@@ -170,10 +170,11 @@ static int lrc_read_header(AVFormatContext *s)
     av_bprint_init(&line, 0, AV_BPRINT_SIZE_UNLIMITED);
 
     while(!avio_feof(s->pb)) {
-        int64_t pos = read_line(&line, s->pb);
+        int64_t header_offset, pos = read_line(&line, s->pb);
+
         if (!av_bprint_is_complete(&line))
             goto err_nomem_out;
-        int64_t header_offset = find_header(line.str);
+        header_offset = find_header(line.str);
         if(header_offset >= 0) {
             char *comma_offset = strchr(line.str, ':');
             if(comma_offset) {



More information about the ffmpeg-cvslog mailing list