From 90b1fa59cfee2d2c469de89e71b6366ebd28a1f3 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Thu, 7 Jun 2018 13:07:52 +0200 Subject: sd-event: document sd_event_source_set_io_fd_own() With this we have 100% of the sd-event symbols documented again. Yay! --- man/sd_event_add_io.xml | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) (limited to 'man/sd_event_add_io.xml') diff --git a/man/sd_event_add_io.xml b/man/sd_event_add_io.xml index d5ef462e53..bd513a7814 100644 --- a/man/sd_event_add_io.xml +++ b/man/sd_event_add_io.xml @@ -38,6 +38,8 @@ sd_event_source_get_io_revents sd_event_source_get_io_fd sd_event_source_set_io_fd + sd_event_source_get_io_fd_own + sd_event_source_set_io_fd_own sd_event_source sd_event_io_handler_t @@ -97,6 +99,17 @@ int fd + + int sd_event_source_get_io_fd_own + sd_event_source *source + + + + int sd_event_source_set_io_fd_own + sd_event_source *source + int b + + @@ -212,6 +225,17 @@ changes the UNIX file descriptor of an I/O event source created previously with sd_event_add_io(). It takes the event source object and the new file descriptor. + + sd_event_source_set_io_fd_own() controls whether the file descriptor of the event source + shall be closed automatically when the event source is freed, i.e. whether it shall be considered 'owned' by the + event source object. By default it is not closed automatically, and the application has to do this on its own. The + b parameter is a boolean parameter: if zero, the file descriptor is not closed automatically + when the event source is freed, otherwise it is closed. + + sd_event_source_get_io_fd_own() may be used to query the current setting of the file + descriptor ownership boolean flag as set with sd_event_source_set_io_fd_own(). It returns + positive if the file descriptor is closed automatically when the event source is destroyed, zero if not, and + negative on error. -- cgit v1.2.1