mirror of
https://github.com/hyprwm/Hyprland.git
synced 2024-12-29 18:53:19 +03:00
screencopy: fix crash in invalid format reads
This commit is contained in:
parent
3ce19e67fe
commit
31963f823b
@ -379,6 +379,7 @@ bool CScreencopyProtocolManager::copyFrameShm(SScreencopyFrame* frame, timespec*
|
||||
const auto PFORMAT = get_gles2_format_from_drm(format);
|
||||
if (!PFORMAT) {
|
||||
Debug::log(ERR, "[screencopy] Cannot read pixels, unsupported format %x", PFORMAT);
|
||||
wlr_output_rollback(PMONITOR->output);
|
||||
pixman_region32_fini(&fakeDamage);
|
||||
wlr_buffer_end_data_ptr_access(frame->buffer);
|
||||
return false;
|
||||
|
Loading…
Reference in New Issue
Block a user