diff options
author | Kristian Høgsberg <krh@bitplanet.net> | 2013-04-02 21:31:02 -0400 |
---|---|---|
committer | Kristian Høgsberg <krh@bitplanet.net> | 2013-04-02 21:31:02 -0400 |
commit | 858fcbde59cfd2b42644c43bf481ffd70b30d5be (patch) | |
tree | 4aaaf0ae787ca34099e4f537c53da4604ce92949 | |
parent | 88d873ecb971a3f2d0f7420edf9711346f0344a3 (diff) |
docs: Document non-blocking behaviour of wl_display_flush()
-rw-r--r-- | src/wayland-client.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/wayland-client.c b/src/wayland-client.c index 0873835..ada4d5e 100644 --- a/src/wayland-client.c +++ b/src/wayland-client.c @@ -1052,7 +1052,7 @@ wl_display_get_error(struct wl_display *display) return ret; } -/** Send all buffered request on the display to the server +/** Send all buffered requests on the display to the server * * \param display The display context object * \return The number of bytes send on success or -1 on failure @@ -1062,6 +1062,11 @@ wl_display_get_error(struct wl_display *display) * of bytes sent to the server is returned. On failure, this * function returns -1 and errno is set appropriately. * + * wl_display_flush() never blocks. It will write as much data as + * possible, but if all data could not be written, errno will be set + * to EAGAIN and -1 returned. In that case, use poll on the display + * file descriptor to wait for it to become writable again. + * * \memberof wl_display */ WL_EXPORT int |