diff mbox series

[FFmpeg-devel,1/3] avformat/avisynth: add missing avs_release_video_frame

Message ID 20220808012532.41519-2-qyot27@gmail.com
State Accepted
Commit f6a36c7cf90dc71400c4a1ba0f5c5e8fbbf6d1bf
Headers show
Series avisynth: miscellaneous fixes | 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

Stephen Hutchinson Aug. 8, 2022, 1:25 a.m. UTC
The AviSynth C API requires using avs_release_video_frame
whenever avs_get_frame has been used, but the recent addition
of frameprop reading to the demuxer was missing this in
avisynth_create_stream_video.

---
 libavformat/avisynth.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Stephen Hutchinson Aug. 12, 2022, 9:25 p.m. UTC | #1
On 8/7/22 9:25 PM, Stephen Hutchinson wrote:
> The AviSynth C API requires using avs_release_video_frame
> whenever avs_get_frame has been used, but the recent addition
> of frameprop reading to the demuxer was missing this in
> avisynth_create_stream_video.
> 
> ---
>   libavformat/avisynth.c | 1 +
>   1 file changed, 1 insertion(+)
> 
> diff --git a/libavformat/avisynth.c b/libavformat/avisynth.c
> index a97d12b6b6..98b4d68a57 100644
> --- a/libavformat/avisynth.c
> +++ b/libavformat/avisynth.c
> @@ -728,6 +728,7 @@ static int avisynth_create_stream_video(AVFormatContext *s, AVStream *st)
>                   st->codecpar->chroma_location = AVCHROMA_LOC_UNSPECIFIED;
>               }
>           }
> +        avs_library.avs_release_video_frame(frame);
>       } else {
>           st->codecpar->field_order = AV_FIELD_UNKNOWN;
>           /* AviSynth works with frame-based video, detecting field order can

Pushed.
diff mbox series

Patch

diff --git a/libavformat/avisynth.c b/libavformat/avisynth.c
index a97d12b6b6..98b4d68a57 100644
--- a/libavformat/avisynth.c
+++ b/libavformat/avisynth.c
@@ -728,6 +728,7 @@  static int avisynth_create_stream_video(AVFormatContext *s, AVStream *st)
                 st->codecpar->chroma_location = AVCHROMA_LOC_UNSPECIFIED;
             }
         }
+        avs_library.avs_release_video_frame(frame);
     } else {
         st->codecpar->field_order = AV_FIELD_UNKNOWN;
         /* AviSynth works with frame-based video, detecting field order can