Skip to content

Commit e9416ab

Browse files
committed
Document inherit_fds option of popen.new
Since version 3.2.0, the ``inherit.fds`` option is added to the ``opts`` table. The option allows define file descriptor numbers that should be left open in the child process if the close_fds flag is set to ``true``. Fixes #3609
1 parent 282ca7c commit e9416ab

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

doc/reference/reference_lua/popen.rst

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -251,14 +251,17 @@ Below is a list of all ``popen`` functions and handle methods.
251251
| | | or when Lua GC collects the handle. |
252252
+----------------------+----------------+-------------------------------------------+
253253

254-
255254
The returned ``ph`` handle provides a
256255
:ref:`popen_handle:close() <popen-close>` method for explicitly
257256
releasing all occupied resources, including the child process
258257
itself if ``opts.keep_child`` is not set). However, if the ``close()``
259258
method is not called for a handle during its lifetime, the
260259
Lua GC will trigger the same freeing actions.
261260

261+
Since version 3.2.0, the ``inherit.fds`` option is added to the ``opts``
262+
table. The option allows define file descriptor numbers that should be
263+
left open in the child process if the close_fds flag is set to ``true``.
264+
262265
Tarantool recommends using ``opts.setsid`` plus ``opts.group_signal``
263266
if a child process may spawn its own children and if they should all
264267
be killed together.

0 commit comments

Comments
 (0)