Commit Graph

542 Commits

Author SHA1 Message Date
sin
6f7f387352 Stop using EXIT_{SUCCESS,FAILURE} 2014-10-02 23:47:39 +01:00
sin
d4416d984b Update TODO 2014-09-28 18:36:05 +01:00
sin
30715f1eec No need for putchar('\n') after getpass() 2014-09-04 11:52:12 +01:00
sin
4a324f6359 Check for cmd truncation in watch(1) 2014-08-25 19:14:57 +01:00
Wolfgang Corcoran-Mathe
9859943d47 Remove unnecessary newline output from su 2014-08-25 15:37:13 +01:00
sin
cd1a3d5698 Rework parsecmdline() 2014-08-20 20:38:35 +01:00
sin
0fbd4280f8 Add lastlog to README 2014-08-18 22:35:13 +01:00
sin
ef78f20dd8 Use agetline() in lastlog(8)
Some other minor changes as well.
2014-08-18 22:03:50 +01:00
sin
1aaec6250a Convert lastlog(8) to {w,}eprintf() 2014-08-18 21:55:38 +01:00
sin
6af24e35f9 Only check errno if getpwnam() fails 2014-08-18 21:49:22 +01:00
Roberto E. Vargas Caballero
e4677f290b Add lastlog(8)
At the moment this does not work with ubase login(1).  We should
add support to login(1) to write the lastlog entries.

Minor modifications by sin.
2014-08-18 18:29:38 +01:00
sin
1291687152 Only work with stderr in mesg
Previous commit was incomplete (damn git add -p).
2014-08-04 21:04:07 +01:00
sin
af274ce48a Add mesg.1 2014-08-04 21:01:00 +01:00
sin
a068e158e4 Associate perms on stderr as opposed to stdin 2014-08-04 21:00:54 +01:00
sin
cebba6f038 Update TODO 2014-07-27 00:12:05 +01:00
sin
bf9dfd7b29 Only "y" and "n" are valid, nothing else
Good catch FRIGN.
2014-07-26 15:52:44 +01:00
sin
60b1cc522e Add mesg to README 2014-07-26 15:37:16 +01:00
sin
47092bd9b6 Add mesg(1)
No manpage yet.
2014-07-26 15:33:13 +01:00
sin
2e3fae67e2 Add less/pg to TODO 2014-07-14 19:16:52 +01:00
sin
050430c81a Add fakeroot 2014-07-14 19:01:46 +01:00
sin
d10f04c473 Fix include order 2014-07-14 13:30:09 +01:00
Hiltjo Posthuma
8fdc7d70bd passwd: fix /etc/passwd support, ...
... rewrite parts to use libc functions (supported by musl and glibc).
2014-07-14 11:14:36 +01:00
Hiltjo Posthuma
10a539e744 passwd: fix potential double close() 2014-07-12 20:04:29 +01:00
Hiltjo Posthuma
fa0b80442c ps: one case for error handling 2014-07-12 20:04:20 +01:00
Hiltjo Posthuma
f48d545c77 passwd: improvements
- add shadow support.
- allow passwd without argument, prompt which user password is changed.
2014-07-10 22:04:06 +01:00
Hiltjo Posthuma
a27035c281 ps: whoops wrong copy-pasterino 2014-07-09 15:08:21 +01:00
Hiltjo Posthuma
e45e64491e Only check errno if getpwuid() fails
Checking errno otherwise is unspecified.
2014-07-09 15:08:11 +01:00
Hiltjo Posthuma
291aedb875 code consistency fixes 2014-07-09 15:08:01 +01:00
Hiltjo Posthuma
c50f7a3a27 login: separate write utmp in a separate function
write utmp entry (as root) before setuid.
2014-07-09 15:07:53 +01:00
Hiltjo Posthuma
96f15f1d04 errno: check only errno if return value was NULL 2014-07-09 15:07:34 +01:00
Hiltjo Posthuma
528f10be6c util/passwd.c: check errno only if spw is NULL
this is more reliable. there is a difference between glibc and musl
errno if /etc/tcb/<name>/shadow doesn't exist.
2014-07-09 15:07:19 +01:00
sin
10c8b71fd2 Kick off respawn in its own session 2014-07-06 21:36:28 +01:00
sin
ce59961f19 respawn: kill child process upon SIGTERM
We might revisit this and be more strict i.e. kill the child
process even if it is in a new process session/group.

For now this is probably a good enough balance.

This patch changes the existing semantics of respawn, the child
process is now part of the same process session as respawn.
2014-07-06 21:15:09 +01:00
Hiltjo Posthuma
d9aaa0f501 pidof: fix typo, argv[0] -> argv[i] 2014-07-05 16:26:55 +01:00
Hiltjo Posthuma
2557104494 util/proc: theoretical underflow 2014-07-05 12:00:24 +01:00
Hiltjo Posthuma
5a06a9f7e1 pidof: match on full name and basename
busybox doesn't do this, but procps does.
2014-07-05 12:00:17 +01:00
sin
55dd1076fe Print header after trying to open /proc/modules
This fails on kernels compiled without module support or
if procfs is not mounted.
2014-07-04 11:52:09 +01:00
sin
1ec0073bb8 Remove entries from TAILQ when free-ing 2014-07-03 14:29:45 +01:00
sin
c9609ea5ff Only call fwrite() and fclose() when fp is not NULL
Spotted by Hiltjo.
2014-07-02 12:09:01 +01:00
sin
3669fa4117 More error checking for fwrite() 2014-07-02 12:06:26 +01:00
sin
53547b7835 Just die if ttyname() fails 2014-07-02 12:06:16 +01:00
sin
2832db2368 Set UTMP_PATH in config.def.h 2014-07-02 12:06:07 +01:00
sin
d0145aaf1f login: Write utmp entry 2014-07-02 12:05:58 +01:00
sin
ae8ca1598b Clear utmp entries for the specified tty in getty(8) 2014-07-02 12:05:41 +01:00
sin
8d187be64a Replace fprintf(stderr, ...) calls with weprintf() 2014-06-30 22:44:48 +01:00
sin
135f6012cb Incomplete output is not an error 2014-06-30 22:44:26 +01:00
sin
29bc0ce130 No need to skip stdin in chvt(1) 2014-06-30 19:18:49 +01:00
sin
d04d030367 Use EXIT_FAILURE 2014-06-30 19:16:15 +01:00
sin
86060b535c Fix includes across all tools 2014-06-30 19:04:47 +01:00
sin
b03a021983 List function decls in alphabetical order 2014-06-30 18:42:49 +01:00