diff --git a/man/rules/meson.build b/man/rules/meson.build
index 68b7453a114..04f03c67863 100644
--- a/man/rules/meson.build
+++ b/man/rules/meson.build
@@ -280,9 +280,11 @@ manpages = [
'sd_event_source',
'sd_event_source_get_io_events',
'sd_event_source_get_io_fd',
+ 'sd_event_source_get_io_fd_own',
'sd_event_source_get_io_revents',
'sd_event_source_set_io_events',
- 'sd_event_source_set_io_fd'],
+ 'sd_event_source_set_io_fd',
+ 'sd_event_source_set_io_fd_own'],
''],
['sd_event_add_signal',
'3',
diff --git a/man/sd_event_add_io.xml b/man/sd_event_add_io.xml
index d5ef462e537..bd513a78147 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.