Page MenuHomeSolus

mesalib: backport a patch for VAAPI crash

Authored by aleksvor on Sat, May 20, 8:34 PM.



This diff contains a patch that fixes a crash that I found when using mpv. The crash occurs with following clauses and steps:

  1. Use AMD GPU.
  2. Use mpv with gpu-next video output (probably current gpu output is affected too, haven't tried it) and VAAPI hwdec.
  3. Watch a high-bitrate video or livestream and try to seek to the timestamp that wasn't cached yet.

You'll likely get a segfault which traces into This patch adds the necessary nullptr check to prevent this segfault.

Test Plan

Watched a video that I wasn't able to reliably seek previosly when using VAAPI. Now I can seek to any timestamp, and while I can get a few dropped frames, it doesn't crash anymore.

Diff Detail

R2066 mesalib
Lint Not Applicable
Tests Not Applicable