Re: [REQUEST FOR VOTES] snmpd: Call fclose() after fdopen() but not close()

Bart Van Assche <[email protected]>
Newsgroups gmane.network.net-snmp.devel
Message-ID <[email protected]>
On 2020-08-14 17:05, Magnus Fromreide wrote:
> The vfork child only blocks the parent until it have performed an successful
> exec so that part looks ok [ ... ]

Hi Magnus,

Are you sure of this? From the Linux vfork() man page
(https://man7.org/linux/man-pages/man2/vfork.2.html):

The requirements put on vfork() by the standards are weaker than
those put on fork(2), so an implementation where the two are
synonymous is compliant.  In particular, the programmer cannot rely
on the parent remaining blocked until the child either terminates or
calls execve(2), and cannot rely on any specific behavior with
respect to shared memory.

Thanks,

Bart.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.