is fork() supported?
Andrew Haley
aph@redhat.com
Thu Aug 5 08:17:54 GMT 2021
On 8/4/21 9:00 PM, DJ Delorie via Libffi-discuss wrote:
> I don't mean fork/exec (duh) but a fork() and keep going...
>
> Consider a case where a process is using a file-backed mapping for
> closures; a fork() doesn't isolate that backing between parent/child
> so there's a chance (for example) the parent could deallocate a
> closure that the child needs, etc...
>
> I see four options...
>
> 1. Not supported. Sorry.
>
> 2. Supported only if you have fork-able closure backings (mmap or
> maybe ktmpfile, but not file-backed) but this means documenting
> that (at least) selinux settings might affect this. Caveat
> Programmer.
>
> 3. Some API that says "I need this" so it can fail in a more useful
> way than "segfault".
>
> 4. Fully supported, and we have some work to do to handle fork events.
The bug that will never die.
https://bugzilla.redhat.com/show_bug.cgi?id=1249685
https://bugzilla.redhat.com/show_bug.cgi?id=531233
https://bugzilla.redhat.com/show_bug.cgi?id=772657
--
Andrew Haley (he/him)
Java Platform Lead Engineer
Red Hat UK Ltd. <https://www.redhat.com>
https://keybase.io/andrewhaley
EAC8 43EB D3EF DB98 CC77 2FAD A5CD 6035 332F A671
More information about the Libffi-discuss
mailing list