History

gui-wl: take lock when flushing from framedone callback

The wayland callbacks are generally done in another thread, so it was possible to be servicing a flush from the /dev/draw side while also getting a callback.

Jacob Moody committed 2 years ago

Commit ec1fed31 parent 8391a9e1 file · +2 −0Browse files

Unified · Split

gui-wl/wl-cb.c+2−0
@@ -80,7 +80,9 @@ wl_surface_frame_done(void *data, struct wl_callback *cb, uint32_t time) · 79 unmodified lines
8080 wl_callback_destroy(cb);
8181 cb = wl_surface_frame(wl->surface);
8282 wl_callback_add_listener(cb, &wl_surface_frame_listener, wl);
83+ qlock(&drawlock);
8384 wlflush(wl);
85+ qunlock(&drawlock);
8486 }
8587
8688 static void

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t