Skip to content

RFC: plugins/screencast: Refuse creating a dmabuf buffer if n_datas is wrong

n_datas must match the plane count in the graphics buffer. But apparently pw buffers with wrong n_datas can still slip through somehow. It makes the screen cast stream crash when filling in buffer data.

The crash is hard to reproduce, but on the other hand, according to sentry, a substantial number of users is affected by this issue.

Taking the defensive approach is not great, there will likely be other issues with screencasting, but it seems like the only feasible option so far. Broken streams is better than kwin crashing. It also wouldn't hurt to add some warning messages, that will be done in a follow up MR.

Merge request reports