Files
FFmpeg/doc
Jun Zhao 8d80b13cbe doc/examples/remux: fix NULL pointer dereference in cleanup
The cleanup path uses `ofmt->flags` to check AVFMT_NOFILE, but
`ofmt` is only assigned after avformat_alloc_output_context2
succeeds. If a failure occurs between output context allocation
and the `ofmt` assignment (e.g. stream_mapping allocation fails),
ofmt_ctx is non-NULL while ofmt is still NULL, causing a crash.

Use ofmt_ctx->oformat->flags instead, which is always valid when
ofmt_ctx is non-NULL.

Signed-off-by: Jun Zhao <barryjzhao@tencent.com>
2026-03-18 02:08:09 +00:00
..
2023-03-01 21:59:10 +01:00
2026-01-18 03:33:04 +00:00
2025-08-03 13:48:47 +02:00
2025-10-25 13:21:50 +00:00
2024-03-18 17:59:19 +01:00
2025-08-03 13:48:47 +02:00
2026-01-18 03:33:04 +00:00
2025-08-03 13:48:47 +02:00
2021-06-18 18:58:25 +02:00