libc: update O_APPEND fds on joined child

The fds in O_APPEND state may have changed by the child. The local seek
state needs to be valid/current for the next to be forked child, which seek
state is set by File_descriptor_allocator::generate_info().

Issue #3991
This commit is contained in:
Alexander Boettcher
2021-01-20 09:16:27 +01:00
committed by Norman Feske
parent 9bfd812a88
commit 5fa91c573b
3 changed files with 18 additions and 0 deletions

View File

@ -113,6 +113,11 @@ namespace Libc {
*/
File_descriptor *any_cloexec_libc_fd();
/**
* Update seek state of file descriptor with append flag set.
*/
void update_append_libc_fds();
/**
* Return file-descriptor ID of any open file, or -1 if no file is
* open