mirror of
https://gitlab.freedesktop.org/wayland/wayland.git
synced 2025-11-11 13:29:49 -05:00
Always poll on display fd so we only read when there's data.
This commit is contained in:
parent
6b5e7626f5
commit
2a20d83fdb
2 changed files with 29 additions and 7 deletions
|
|
@ -126,6 +126,10 @@ int main(int argc, char *argv[])
|
|||
|
||||
display = wl_display_create(socket_name,
|
||||
connection_update, &p[0]);
|
||||
if (display == NULL) {
|
||||
fprintf(stderr, "failed to create display: %m\n");
|
||||
return -1;
|
||||
}
|
||||
p[0].fd = wl_display_get_fd(display);
|
||||
|
||||
surface = wl_display_create_surface(display);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue