<feed xmlns='http://www.w3.org/2005/Atom'>
<title>src/lib/libc/stdlib/system.c, branch release/14.4.0</title>
<subtitle>FreeBSD source tree</subtitle>
<id>https://cgit-dev.freebsd.org/src/atom?h=release%2F14.4.0</id>
<link rel='self' href='https://cgit-dev.freebsd.org/src/atom?h=release%2F14.4.0'/>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/'/>
<updated>2023-11-27T04:20:09Z</updated>
<entry>
<title>libc: Purge unneeded cdefs.h</title>
<updated>2023-11-27T04:20:09Z</updated>
<author>
<name>Warner Losh</name>
<email>imp@FreeBSD.org</email>
</author>
<published>2023-11-01T22:43:37Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=4025b5b527c870cf095ac9531764f4e4d3feaec2'/>
<id>urn:sha1:4025b5b527c870cf095ac9531764f4e4d3feaec2</id>
<content type='text'>
These sys/cdefs.h are not needed. Purge them. They are mostly left-over
from the $FreeBSD$ removal. A few in libc are still required for macros
that cdefs.h defines. Keep those.

Sponsored by:		Netflix
Differential Revision:	https://reviews.freebsd.org/D42385

(cherry picked from commit 559a218c9b257775fb249b67945fe4a05b7a6b9f)
</content>
</entry>
<entry>
<title>Remove $FreeBSD$: one-line .c pattern</title>
<updated>2023-08-16T17:54:42Z</updated>
<author>
<name>Warner Losh</name>
<email>imp@FreeBSD.org</email>
</author>
<published>2023-08-16T17:54:42Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=1d386b48a555f61cb7325543adbbb5c3f3407a66'/>
<id>urn:sha1:1d386b48a555f61cb7325543adbbb5c3f3407a66</id>
<content type='text'>
Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
</content>
</entry>
<entry>
<title>General further adoption of SPDX licensing ID tags.</title>
<updated>2017-11-20T19:49:47Z</updated>
<author>
<name>Pedro F. Giffuni</name>
<email>pfg@FreeBSD.org</email>
</author>
<published>2017-11-20T19:49:47Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=8a16b7a18f5d0b031f09832fd7752fba717e2a97'/>
<id>urn:sha1:8a16b7a18f5d0b031f09832fd7752fba717e2a97</id>
<content type='text'>
Mainly focus on files that use BSD 3-Clause license.

The Software Package Data Exchange (SPDX) group provides a specification
to make it easier for automated tools to detect and summarize well known
opensource licenses. We are gradually adopting the specification, noting
that the tags are considered only advisory and do not, in any way,
superceed or replace the license texts.

Special thanks to Wind River for providing access to "The Duke of
Highlander" tool: an older (2014) run over FreeBSD tree was useful as a
starting point.
</content>
</entry>
<entry>
<title>Switch libc from using _sig{procmask,action,suspend} symbols, which</title>
<updated>2015-08-29T14:25:01Z</updated>
<author>
<name>Konstantin Belousov</name>
<email>kib@FreeBSD.org</email>
</author>
<published>2015-08-29T14:25:01Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=bd6060a1c661b37b3f39a8b92ddea8725ae34fb1'/>
<id>urn:sha1:bd6060a1c661b37b3f39a8b92ddea8725ae34fb1</id>
<content type='text'>
are aliases for the syscall stubs and are plt-interposed, to the
libc-private aliases of internally interposed sigprocmask() etc.

Since e.g. _sigaction is not interposed by libthr, calling signal()
removes thr_sighandler() from the handler slot etc.  The result was
breaking signal semantic and rtld locking.

The added __libc_sigprocmask and other symbols are hidden, they are
not exported and cannot be called through PLT.  The setjmp/longjmp
functions for x86 were changed to use direct calls, and since
PIC_PROLOGUE only needed for functional PLT indirection on i386, it is
removed as well.

The PowerPC bug of calling the syscall directly in the setjmp/longjmp
implementation is kept as is.

Reported by:	Pete French &lt;petefrench@ingresso.co.uk&gt;
Tested by:	Michiel Boland &lt;boland37@xs4all.nl&gt;
Reviewed by:	jilles (previous version)
Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
</content>
</entry>
<entry>
<title>Fix known issues which blow up the process after dlopen("libthr.so")</title>
<updated>2015-01-03T18:38:46Z</updated>
<author>
<name>Konstantin Belousov</name>
<email>kib@FreeBSD.org</email>
</author>
<published>2015-01-03T18:38:46Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=8495e8b1e9e13fb707296a486acf7538dbfa12b2'/>
<id>urn:sha1:8495e8b1e9e13fb707296a486acf7538dbfa12b2</id>
<content type='text'>
(or loading a dso linked to libthr.so into process which was not
linked against threading library).

- Remove libthr interposers of the libc functions, including
  __error(). Instead, functions calls are indirected through the
  interposing table, similar to how pthread stubs in libc are already
  done.  Libc by default points either to syscall trampolines or to
  existing libc implementations.  On libthr load, libthr rewrites the
  pointers to the cancellable implementations already in libthr.  The
  interposition table is separate from pthreads stubs indirection
  table to not pull pthreads stubs into static binaries.

- Postpone the malloc(3) internal mutexes initialization until libthr
  is loaded.  This avoids recursion between calloc(3) and static
  pthread_mutex_t initialization.

- Reinstall signal handlers with wrapper on libthr load.  The
  _rtld_is_dlopened(3) is used to avoid useless calls to sigaction(2)
  when libthr is statically referenced from the main binary.

In the process, fix openat(2), swapcontext(2) and setcontext(2)
interposing.  The libc symbols were exported at different versions
than libthr interposers.  Export both libc and libthr versions from
libc now, with default set to the higher version from libthr.

Remove unused and disconnected swapcontext(3) userspace implementation
from libc/gen.

No objections from:	deischen
Tested by:	pho, antoine (exp-run) (previous versions)
Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
</content>
</entry>
<entry>
<title>system(): Restore behaviour for SIGINT and SIGQUIT.</title>
<updated>2013-09-01T19:59:54Z</updated>
<author>
<name>Jilles Tjoelker</name>
<email>jilles@FreeBSD.org</email>
</author>
<published>2013-09-01T19:59:54Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=865ca149dcac626ebca40ae3ea5c8009af91e671'/>
<id>urn:sha1:865ca149dcac626ebca40ae3ea5c8009af91e671</id>
<content type='text'>
As mentioned in r16117 and the book "Advanced Programming in the Unix
Environment" by W. Richard Stevens, we should ignore SIGINT and SIGQUIT
before forking, since it is not guaranteed that the parent process starts
running soon enough.

To avoid calling sigaction() in the vforked child, instead block SIGINT and
SIGQUIT before vfork() and keep the sigaction() to ignore after vfork(). The
FreeBSD kernel discards ignored signals, even if they are blocked;
therefore, it is not necessary to unblock SIGINT and SIGQUIT earlier.
</content>
</entry>
<entry>
<title>vfork(2) was listed as deprecated in 1994 (r1573) and was the false</title>
<updated>2013-08-13T20:38:55Z</updated>
<author>
<name>Peter Wemm</name>
<email>peter@FreeBSD.org</email>
</author>
<published>2013-08-13T20:38:55Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=7d1ffcb72ac881b52c8b79bedbb120e92ee7141b'/>
<id>urn:sha1:7d1ffcb72ac881b52c8b79bedbb120e92ee7141b</id>
<content type='text'>
reports of its impending demise were removed in 2009 (r199257).

However, in 1996 (r16117) system(3) was switched from vfork(2) to
fork(2) based partly on this.  Switch back to vfork(2).  This has a
dramatic effect in cases of extreme mmap use - such as excessive
abuse (500+) of shared libraries.

popen(3) has used vfork(2) for a while.  vfork(2) isn't going anywhere.
</content>
</entry>
<entry>
<title>Renumber clauses to reduce diffs to other versions</title>
<updated>2013-06-13T00:19:30Z</updated>
<author>
<name>Ed Maste</name>
<email>emaste@FreeBSD.org</email>
</author>
<published>2013-06-13T00:19:30Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=580b4d185bc1d20da91429229920ce590309cbf6'/>
<id>urn:sha1:580b4d185bc1d20da91429229920ce590309cbf6</id>
<content type='text'>
NetBSD, OpenBSD, and Android's Bionic number the clauses 1 through 3,
so follow suit to make comparison easier.
</content>
</entry>
<entry>
<title>Fix many "function declaration isn't a prototype" warnings in libc.</title>
<updated>2009-12-05T19:31:38Z</updated>
<author>
<name>Ed Schouten</name>
<email>ed@FreeBSD.org</email>
</author>
<published>2009-12-05T19:31:38Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=2c201a9afe37d2cec72faa4f00dc640c7b4130b3'/>
<id>urn:sha1:2c201a9afe37d2cec72faa4f00dc640c7b4130b3</id>
<content type='text'>
I've only fixed code that seems to be written by `us'. There are still
many warnings like this present in resolv/, rpc/, stdtime/ and yp/.
</content>
</entry>
<entry>
<title>Per Regents of the University of Calfornia letter, remove advertising</title>
<updated>2007-01-09T00:28:16Z</updated>
<author>
<name>Warner Losh</name>
<email>imp@FreeBSD.org</email>
</author>
<published>2007-01-09T00:28:16Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=c879ae3536e6d92b8d96c8965c5b05fcb9541520'/>
<id>urn:sha1:c879ae3536e6d92b8d96c8965c5b05fcb9541520</id>
<content type='text'>
clause.

# If I've done so improperly on a file, please let me know.
</content>
</entry>
</feed>
