summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <[email protected]>2024-04-27 22:20:25 +0200
committerMichael Niedermayer <[email protected]>2024-07-02 21:57:18 +0200
commit97b2ab15de964d9455aa902ab616881f76d2cb67 (patch)
tree7350b7fef165675caee15d50943adb8fb380b3c5
parent2882d30e3acfc3155e2be11db653c7c721f94f34 (diff)
fftools/ffmpeg_enc: simplify opaque_ref check
Found-while-revieweing: CID1520670 Dereference after null check Sponsored-by: Sovereign Tech Fund Signed-off-by: Michael Niedermayer <[email protected]>
-rw-r--r--fftools/ffmpeg_enc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fftools/ffmpeg_enc.c b/fftools/ffmpeg_enc.c
index 618ba193ff..863d1a43ed 100644
--- a/fftools/ffmpeg_enc.c
+++ b/fftools/ffmpeg_enc.c
@@ -476,7 +476,7 @@ void enc_stats_write(OutputStream *ost, EncStats *es,
const FrameData *fd;
- if ((frame && frame->opaque_ref) || (pkt && pkt->opaque_ref)) {
+ if (frame ? frame->opaque_ref : pkt->opaque_ref) {
fd = (const FrameData*)(frame ? frame->opaque_ref->data : pkt->opaque_ref->data);
tbi = fd->dec.tb;
ptsi = fd->dec.pts;