Commit Graph

311 Commits

Author SHA1 Message Date
Jonas 'Sortie' Termansen b38c84852c Add pseudo terminals.
This is a compatible ABI change riding on the previous commit's bump.
2016-11-23 22:31:05 +01:00
Jonas 'Sortie' Termansen db7182ddc3 Add support for sessions.
This change refactors the process group implementation and adds support
for sessions. The setsid(2) and getsid(2) system calls were added.

psctl(2) now has PSCTL_TTYNAME, which lets you get the name of a process's
terminal, and ps(1) now uses it.

The initial terminal is now called /dev/tty1.

/dev/tty is now a factory for the current terminal.

A global lock now protects the process hierarchy which makes it safe to
access other processes. This refactor removes potential vulnerabilities
and increases system robustness.

A number of terminal ioctls have been added.

This is a compatible ABI change.
2016-11-23 22:30:47 +01:00
Nicholas De Nova a942b15f91 Add errc(3) family. 2016-11-06 15:31:52 -06:00
Jonas 'Sortie' Termansen 67471b55e7 Add nl_langinfo(3). 2016-10-03 20:02:12 +02:00
Jonas 'Sortie' Termansen 01a9779fc6 Compile libc with -ffreestanding.
This properly avoids problems where the compiler is unaware that this is the
implementation and assumes it can rely on the implementation. For instance,
it might implement calloc using a call to calloc.

Restructure the code that wrongly assumed __STDC_HOSTED__ meant userspace.
2016-05-15 22:43:29 +02:00
Jonas 'Sortie' Termansen 2a6a246ff4 Remove getdomainname(2). 2016-05-15 22:43:29 +02:00
Jonas 'Sortie' Termansen 443b4797bb Add dirname and basename to libk. 2016-03-07 17:46:14 +01:00
Jonas 'Sortie' Termansen 8e988c1bf1 Convert libpthread to C and merge into libc. 2016-03-03 23:02:23 +01:00
Jonas 'Sortie' Termansen 01b59c1947 Convert libc to C. 2016-03-03 23:02:23 +01:00
Jonas 'Sortie' Termansen b5f9876089 Remove unnecessary libg.a. 2016-01-26 21:17:08 +01:00
Jonas 'Sortie' Termansen 9e6876ff14 Split fdio into multiple files. 2016-01-26 19:01:36 +01:00
Jonas 'Sortie' Termansen 3320e29c95 Remove unused libc signal assembly files. 2016-01-26 19:01:36 +01:00
Jonas 'Sortie' Termansen 4d2901b90e Split stdin, stdout and stderr into their own files. 2016-01-26 19:01:36 +01:00
Jonas 'Sortie' Termansen 2e4b15daed Simplify directory reading. 2016-01-26 18:42:54 +01:00
Jonas 'Sortie' Termansen bb73362d23 Create stdio buffers at FILE creation time.
This removes support for user-supplied buffers with setvbuf.
2016-01-26 18:39:48 +01:00
Jonas 'Sortie' Termansen 63d42cd686 Add fstab(3). 2016-01-25 17:42:25 +01:00
Jonas 'Sortie' Termansen bff1265d62 Add termios(2). 2016-01-25 15:47:40 +01:00
Jonas 'Sortie' Termansen fbfe159046 Add crypt_checkpass(3) and crypt_newhash(3). 2016-01-09 02:54:51 +01:00
Jonas 'Sortie' Termansen 53711549af Add bcrypt_checkhash(3) and bcrypt_newhash(3). 2016-01-09 02:54:51 +01:00
Jonas 'Sortie' Termansen 02f95d6c1c Add in6addr_any and in6addr_loopback. 2015-12-18 01:34:37 +01:00
Jonas 'Sortie' Termansen 75808c637d Add regex(3). 2015-12-17 23:32:43 +01:00
Jonas 'Sortie' Termansen 5a3e181975 Add stack smash protection support. 2015-12-12 22:53:07 +01:00
Jonas 'Sortie' Termansen 9b6d60d9d2 Add undefined behavior sanitizer support. 2015-12-12 22:53:07 +01:00
Jonas 'Sortie' Termansen 4b6b06bbc8 Add scram(2). 2015-12-12 22:53:07 +01:00
Jonas 'Sortie' Termansen cee24359d8 Add psctl(2). 2015-12-12 19:28:07 +01:00
Jonas 'Sortie' Termansen 213b3636bb Add open_memstream(3). 2015-08-26 18:10:24 +02:00
Jonas 'Sortie' Termansen f1571ebaf4 Add err(3). 2015-08-26 18:10:24 +02:00
Jonas 'Sortie' Termansen 59e7dd00c5 Add mkdtemps(3). 2015-08-26 16:49:18 +02:00
Jonas 'Sortie' Termansen 5915e2cd14 Add closefrom(2). 2015-08-26 14:01:25 +02:00
Jonas 'Sortie' Termansen 4cb9ccfc4b Rename libc/time/times.cpp to libc/sys/times/times.cpp. 2015-08-22 01:29:37 +02:00
Jonas 'Sortie' Termansen 6405e2ea6e Add arc4random support to the kernel. 2015-08-22 01:04:58 +02:00
Jonas 'Sortie' Termansen 91ab47f99c Deprecate stdio_ext API. 2015-08-21 21:25:01 +02:00
Jonas 'Sortie' Termansen e259e8ae52 Use standard compiler environment variables. 2015-05-10 16:56:22 +02:00
Jonas 'Sortie' Termansen 25482f875e Remove mktemp(3). 2015-04-13 00:00:29 +02:00
Jonas 'Sortie' Termansen 8cd4c1f5a0 Add mkdtemp(3). 2015-02-09 18:56:14 +01:00
Jonas 'Sortie' Termansen f0e3e2cfef Add mkostemps(3) family. 2015-02-09 18:56:14 +01:00
Jonas 'Sortie' Termansen d890d3082d Add umount(2) and unmountat(2). 2014-12-26 21:45:29 +01:00
Jonas 'Sortie' Termansen 3917f4fee3 Use PWD in get_current_dir_name(3) if correct. 2014-12-04 17:56:47 +01:00
Jonas 'Sortie' Termansen 261b95e0a6 Add reallocarray(3). 2014-12-03 23:55:55 +01:00
Jonas 'Sortie' Termansen 5143f01b0a Remove sbrk(2).
Note: This is an incompatible ABI change.
2014-12-03 23:55:55 +01:00
Jonas 'Sortie' Termansen 74247eb71e Rewrite malloc(3). 2014-12-03 21:32:50 +01:00
Jonas 'Sortie' Termansen 52abb4d899 Refuse to implement gethostent(3). 2014-12-03 14:19:58 +01:00
Jonas 'Sortie' Termansen 3ad7ab4fc3 Add gethostname(2) and sethostname(2). 2014-12-03 13:58:29 +01:00
Jonas 'Sortie' Termansen 3a3fc76c8c Remove tmpnam(3). 2014-12-02 18:00:38 +01:00
Jonas 'Sortie' Termansen 2586685061 Ongoing build system maintainance. 2014-12-02 17:09:28 +01:00
Jonas 'Sortie' Termansen ec7e0cc9a6 Add cbprintf(3) and vcbprintf(3).
Thanks to Owen Shepherd of the Public Domain C Library for helping design
and formalize these interfaces.
2014-12-01 21:39:05 +01:00
Jonas 'Sortie' Termansen 8643c37102 Remove __flbf(3). 2014-12-01 21:39:05 +01:00
Jonas 'Sortie' Termansen 2f393b2646 Remove _flushlbf(3). 2014-12-01 21:39:05 +01:00
Jonas 'Sortie' Termansen 3778dae725 Remove __fsetlocking(3). 2014-12-01 21:39:05 +01:00
Jonas 'Sortie' Termansen 35708fa900 Retire calltrace support in favor of the kernel debugger. 2014-12-01 21:38:06 +01:00