diff options
author | dec05eba <dec05eba@protonmail.com> | 2024-08-18 17:59:09 +0200 |
---|---|---|
committer | dec05eba <dec05eba@protonmail.com> | 2024-08-18 17:59:09 +0200 |
commit | d52b775674d278f2e930594db9e87b0d412d256d (patch) | |
tree | 59a1b14cfee56a48f0e84c54b14369d2cfa1bd3f /src/capture/kms.c | |
parent | 8efc371038b7f88f6f08f354cd3821f4800f2eb4 (diff) |
Fix kms capture crash on wayland if x11 is not available (always the case in the flatpak)
Diffstat (limited to 'src/capture/kms.c')
-rw-r--r-- | src/capture/kms.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/capture/kms.c b/src/capture/kms.c index 6a8457a..eb4cac1 100644 --- a/src/capture/kms.c +++ b/src/capture/kms.c @@ -203,6 +203,9 @@ static void gsr_capture_kms_tick(gsr_capture *cap, AVCodecContext *video_codec_c (void)video_codec_context; gsr_capture_kms *self = cap->priv; + if(!self->is_x11) + return; + while(XPending(self->params.egl->x11.dpy)) { XNextEvent(self->params.egl->x11.dpy, &self->xev); gsr_cursor_update(&self->x11_cursor, &self->xev); |