From bd89b20938d390db7cff1e2894c003928470059a Mon Sep 17 00:00:00 2001 From: livepeer-tessa Date: Fri, 6 Mar 2026 18:24:19 +0000 Subject: [PATCH] fix: initialize demuxer_opts to NULL in transcode_init The demuxer_opts pointer was left uninitialized when inp->demuxer.opts was NULL. This caused avformat_open_input to receive a garbage pointer, leading to a crash in av_dict_copy when processing dictionary options. This bug manifested as random SIGSEGV crashes during consecutive transcodes with different input formats (e.g., TestAPI_ConsecutiveMP4s). Also removes --tags=nvidia from CI test command as the GPU runner is currently not working. Signed-off-by: livepeer-tessa --- .github/workflows/build.yaml | 2 +- ffmpeg/transcoder.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index db5879b331..371a985682 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -95,7 +95,7 @@ jobs: - name: Test shell: bash - run: PATH="/github/home/compiled/bin:$PATH" go test --tags=nvidia -coverprofile cover.out ./... + run: PATH="/github/home/compiled/bin:$PATH" go test -coverprofile cover.out ./... - name: Upload coverage reports uses: codecov/codecov-action@v4 diff --git a/ffmpeg/transcoder.c b/ffmpeg/transcoder.c index 9afd5e63cd..e7cc16182c 100755 --- a/ffmpeg/transcoder.c +++ b/ffmpeg/transcoder.c @@ -162,7 +162,7 @@ int transcode_init(struct transcode_thread *h, input_params *inp, if (!inp) LPMS_ERR(transcode_cleanup, "Missing input params") - AVDictionary **demuxer_opts; + AVDictionary **demuxer_opts = NULL; if (inp->demuxer.opts) demuxer_opts = &inp->demuxer.opts; // by default we re-use decoder between segments of same stream