diff mbox series

[FFmpeg-devel,19/21] fftools/ffmpeg_enc: constify the subtitle passed to enc_subtitle()

Message ID 20230614164908.28712-19-anton@khirnov.net
State Accepted
Commit fa717baaa599b07eb647cf70a527b98b18c8236e
Headers show
Series [FFmpeg-devel,01/21] fftools/ffmpeg_dec: drop always-0 InputStream.prev_sub.ret | expand

Checks

Context Check Description
yinshiyou/make_loongarch64 success Make finished
yinshiyou/make_fate_loongarch64 success Make fate finished
andriy/make_x86 success Make finished
andriy/make_fate_x86 success Make fate finished

Commit Message

Anton Khirnov June 14, 2023, 4:49 p.m. UTC
---
 fftools/ffmpeg.h     | 2 +-
 fftools/ffmpeg_enc.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/fftools/ffmpeg.h b/fftools/ffmpeg.h
index 63ca542337..3da5bc4f7c 100644
--- a/fftools/ffmpeg.h
+++ b/fftools/ffmpeg.h
@@ -816,7 +816,7 @@  int enc_alloc(Encoder **penc, const AVCodec *codec);
 void enc_free(Encoder **penc);
 
 int enc_open(OutputStream *ost, AVFrame *frame);
-void enc_subtitle(OutputFile *of, OutputStream *ost, AVSubtitle *sub);
+void enc_subtitle(OutputFile *of, OutputStream *ost, const AVSubtitle *sub);
 void enc_frame(OutputStream *ost, AVFrame *frame);
 void enc_flush(void);
 
diff --git a/fftools/ffmpeg_enc.c b/fftools/ffmpeg_enc.c
index f42f4055d6..4029501313 100644
--- a/fftools/ffmpeg_enc.c
+++ b/fftools/ffmpeg_enc.c
@@ -462,7 +462,7 @@  static int check_recording_time(OutputStream *ost, int64_t ts, AVRational tb)
     return 1;
 }
 
-void enc_subtitle(OutputFile *of, OutputStream *ost, AVSubtitle *sub)
+void enc_subtitle(OutputFile *of, OutputStream *ost, const AVSubtitle *sub)
 {
     Encoder *e = ost->enc;
     int subtitle_out_max_size = 1024 * 1024;