<feed xmlns='http://www.w3.org/2005/Atom'>
<title>src/lib/libc/sys/rfork.2, branch releng/14.0</title>
<subtitle>FreeBSD source tree</subtitle>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/'/>
<entry>
<title>Remove $FreeBSD$: two-line nroff pattern</title>
<updated>2023-08-16T17:55:10+00:00</updated>
<author>
<name>Warner Losh</name>
<email>imp@FreeBSD.org</email>
</author>
<published>2023-08-16T17:55:10+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=fa9896e082a1046ff4fbc75fcba4d18d1f2efc19'/>
<id>fa9896e082a1046ff4fbc75fcba4d18d1f2efc19</id>
<content type='text'>
Remove /^\.\\"\n\.\\"\s*\$FreeBSD\$$\n/
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Remove /^\.\\"\n\.\\"\s*\$FreeBSD\$$\n/
</pre>
</div>
</content>
</entry>
<entry>
<title>posix_spawn(3): handle potential signal issues with vfork</title>
<updated>2019-09-25T19:22:03+00:00</updated>
<author>
<name>Kyle Evans</name>
<email>kevans@FreeBSD.org</email>
</author>
<published>2019-09-25T19:22:03+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=c34a5f16faf5d6d108323eb35bc045e9bb22d1ff'/>
<id>c34a5f16faf5d6d108323eb35bc045e9bb22d1ff</id>
<content type='text'>
Described in [1], signal handlers running in a vfork child have
opportunities to corrupt the parent's state. Address this by adding a new
rfork(2) flag, RFSPAWN, that has vfork(2) semantics but also resets signal
handlers in the child during creation.

x86 uses rfork_thread(3) instead of a direct rfork(2) because rfork with
RFMEM/RFSPAWN cannot work when the return address is stored on the stack --
further information about this problem is described under RFMEM in the
rfork(2) man page.

Addressing this has been identified as a prerequisite to using posix_spawn
in subprocess on FreeBSD [2].

[1] https://ewontfix.com/7/
[2] https://bugs.python.org/issue35823

Reviewed by:	jilles, kib
Differential Revision:	https://reviews.freebsd.org/D19058
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Described in [1], signal handlers running in a vfork child have
opportunities to corrupt the parent's state. Address this by adding a new
rfork(2) flag, RFSPAWN, that has vfork(2) semantics but also resets signal
handlers in the child during creation.

x86 uses rfork_thread(3) instead of a direct rfork(2) because rfork with
RFMEM/RFSPAWN cannot work when the return address is stored on the stack --
further information about this problem is described under RFMEM in the
rfork(2) man page.

Addressing this has been identified as a prerequisite to using posix_spawn
in subprocess on FreeBSD [2].

[1] https://ewontfix.com/7/
[2] https://bugs.python.org/issue35823

Reviewed by:	jilles, kib
Differential Revision:	https://reviews.freebsd.org/D19058
</pre>
</div>
</content>
</entry>
<entry>
<title>rfork(2): add RFSPAWN flag</title>
<updated>2019-09-25T19:20:41+00:00</updated>
<author>
<name>Kyle Evans</name>
<email>kevans@FreeBSD.org</email>
</author>
<published>2019-09-25T19:20:41+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=079c5b9ed809af6dec664accc70119a4ef989420'/>
<id>079c5b9ed809af6dec664accc70119a4ef989420</id>
<content type='text'>
When RFSPAWN is passed, rfork exhibits vfork(2) semantics but also resets
signal handlers in the child during creation to avoid a point of corruption
of parent state from the child.

This flag will be used by posix_spawn(3) to handle potential signal issues.

Reviewed by:	jilles, kib
Differential Revision:	https://reviews.freebsd.org/D19058
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When RFSPAWN is passed, rfork exhibits vfork(2) semantics but also resets
signal handlers in the child during creation to avoid a point of corruption
of parent state from the child.

This flag will be used by posix_spawn(3) to handle potential signal issues.

Reviewed by:	jilles, kib
Differential Revision:	https://reviews.freebsd.org/D19058
</pre>
</div>
</content>
</entry>
<entry>
<title>Document RFTSIGZMB. Fix spelling of SIGCHLD. Note that signals are</title>
<updated>2011-07-12T20:38:42+00:00</updated>
<author>
<name>Konstantin Belousov</name>
<email>kib@FreeBSD.org</email>
</author>
<published>2011-07-12T20:38:42+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=134e789b67a65be9750b536ba440bdee4cf53163'/>
<id>134e789b67a65be9750b536ba440bdee4cf53163</id>
<content type='text'>
delivered, not returned.

MFC after:	1 week
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
delivered, not returned.

MFC after:	1 week
</pre>
</div>
</content>
</entry>
<entry>
<title>rfork(2): Discourage rfork_thread-like approaches.</title>
<updated>2011-03-15T23:51:47+00:00</updated>
<author>
<name>Jilles Tjoelker</name>
<email>jilles@FreeBSD.org</email>
</author>
<published>2011-03-15T23:51:47+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=dd888c677bcb853cfcbdb304f2c9d19a2764acbf'/>
<id>dd888c677bcb853cfcbdb304f2c9d19a2764acbf</id>
<content type='text'>
Calling rfork_thread(3) does not interoperate with pthreads and global state
is not properly protected.

Remove the BUGS section suggesting LinuxThreads entirely. With the current
pthread library libthr, all threads are kernel-level entities so there seems
little reason to use LinuxThreads.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Calling rfork_thread(3) does not interoperate with pthreads and global state
is not properly protected.

Remove the BUGS section suggesting LinuxThreads entirely. With the current
pthread library libthr, all threads are kernel-level entities so there seems
little reason to use LinuxThreads.
</pre>
</div>
</content>
</entry>
<entry>
<title>Document RFTHREAD</title>
<updated>2007-05-14T13:58:54+00:00</updated>
<author>
<name>Pav Lucistnik</name>
<email>pav@FreeBSD.org</email>
</author>
<published>2007-05-14T13:58:54+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=79df5e05ee582e4948c7cecbf834f725fd1e8b18'/>
<id>79df5e05ee582e4948c7cecbf834f725fd1e8b18</id>
<content type='text'>
PR:		docs/78915
Submitted by:	Marc Olzheim &lt;marcolz@stack.nl&gt;
MFC after:	1 week
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
PR:		docs/78915
Submitted by:	Marc Olzheim &lt;marcolz@stack.nl&gt;
MFC after:	1 week
</pre>
</div>
</content>
</entry>
<entry>
<title>Expand *n't contractions.</title>
<updated>2005-02-13T22:25:33+00:00</updated>
<author>
<name>Ruslan Ermilov</name>
<email>ru@FreeBSD.org</email>
</author>
<published>2005-02-13T22:25:33+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=0227791b40a6936310e1dd376b0883b540fec0c0'/>
<id>0227791b40a6936310e1dd376b0883b540fec0c0</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Sort sections.</title>
<updated>2005-01-20T09:17:07+00:00</updated>
<author>
<name>Ruslan Ermilov</name>
<email>ru@FreeBSD.org</email>
</author>
<published>2005-01-20T09:17:07+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=24a0682c6465290759ed0b09ea16e40e7cd47053'/>
<id>24a0682c6465290759ed0b09ea16e40e7cd47053</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Mechanically kill hard sentence breaks.</title>
<updated>2004-07-02T23:52:20+00:00</updated>
<author>
<name>Ruslan Ermilov</name>
<email>ru@FreeBSD.org</email>
</author>
<published>2004-07-02T23:52:20+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=1a0a934547909744a6a2fa4cfd5b795ec6394f05'/>
<id>1a0a934547909744a6a2fa4cfd5b795ec6394f05</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Correct the return value of vfork(2) and rfork(2) in their</title>
<updated>2003-04-27T21:01:34+00:00</updated>
<author>
<name>Robert Drehmel</name>
<email>robert@FreeBSD.org</email>
</author>
<published>2003-04-27T21:01:34+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.freebsd.org/src/commit/?id=d1c2c89dd268a7a60e38b34cda99f4897f047f71'/>
<id>d1c2c89dd268a7a60e38b34cda99f4897f047f71</id>
<content type='text'>
manual page function prototypes.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
manual page function prototypes.
</pre>
</div>
</content>
</entry>
</feed>
