aboutsummaryrefslogtreecommitdiffstats
path: root/swaynag/swaynag.c
diff options
context:
space:
mode:
authorLibravatar emersion <contact@emersion.fr>2018-11-25 18:10:01 +0100
committerLibravatar emersion <contact@emersion.fr>2018-11-25 18:10:01 +0100
commit814dc1dfe5bbfa47a0cfbcfe2c7dd7119b0bad7e (patch)
treebdaaf06ed6def2e4f97128077eb5afa587b9d99c /swaynag/swaynag.c
parentMerge pull request #3184 from kupospelov/fix-resize (diff)
downloadsway-814dc1dfe5bbfa47a0cfbcfe2c7dd7119b0bad7e.tar.gz
sway-814dc1dfe5bbfa47a0cfbcfe2c7dd7119b0bad7e.tar.zst
sway-814dc1dfe5bbfa47a0cfbcfe2c7dd7119b0bad7e.zip
swayidle: fix busy loop on writable FD
The wl_event_source_fd_update docs say: > File descriptors are usually writable to begin with, so they do not need to > be polled for writable until a write actually fails. When a write fails, > the event mask can be changed to poll for readable and writable, delivering > a dispatch callback when it is possible to write more. Once all data has > been written, the mask can be changed to poll only for readable to avoid > busy-looping on dispatch. So we should only poll for WL_EVENT_WRITABLE if a write fails. I'm not yet sure how to do this properly and Weston doesn't do it, so in the meantime I'll just fix the busy loop. I'll ask them too. Fixes https://github.com/swaywm/sway/issues/3190
Diffstat (limited to 'swaynag/swaynag.c')
0 files changed, 0 insertions, 0 deletions