Ed Schouten
c3f1b3ae09
Let the size of the namebuf depend on the size of the ut_user field.
2011-06-18 07:47:15 +00:00
Joel Dahl
da52b4caaf
Remove the advertising clause from UCB copyrighted files in usr.bin. This
...
is in accordance with the information provided at
ftp://ftp.cs.berkeley.edu/pub/4bsd/README.Impt.License.Change
Also add $FreeBSD$ to a few files to keep svn happy.
Discussed with: imp, rwatson
2010-12-11 08:32:16 +00:00
Ed Schouten
ab90a4d1e2
Perform all trivial ports to utmpx for usr.bin/.
...
They were already converted to use libulog, so it's easy to convert them
to utmpx.
2010-01-13 18:09:54 +00:00
Ed Schouten
cfe41e3b68
Use _ULOG_POSIX_NAMES here, to make eventual porting to <utmpx.h> easier.
...
By the time we gain a real <utmpx.h>, it's just a matter of changing the
include at the top and -lulog from the Makefile.
2009-12-05 19:54:37 +00:00
Ed Schouten
178442d07a
Use USER_PROCESS instead of LOGIN_PROCESS.
...
POSIX isn't clear about how the fields should be used, but according to
utmpx(5) on Linux, LOGIN_PROCESS refers to a TTY that's still running a
getty.
2009-12-03 17:05:36 +00:00
Ed Schouten
42b525af6e
Port users(1) to libulog.
...
Instead of digging through the utmp database by hand, use proper API
calls to do so. Instead of parsing entries with a non-empty ut_user, we
now look at LOGIN_PROCESS entries.
2009-12-03 16:42:18 +00:00
David Malone
f4ac32def2
ANSIify function definitions.
...
Add some constness to avoid some warnings.
Remove use register keyword.
Deal with missing/unneeded extern/prototypes.
Some minor type changes/casts to avoid warnings.
Reviewed by: md5
2002-09-04 23:29:10 +00:00
Warner Losh
3f330d7d1a
remove __P
2002-03-22 01:42:45 +00:00
Mike Barcroft
0caf2ae89d
Remove a bogus cast and lockdown users(1) with WARNS?=2
...
Submitted by: David Hill <david@phobia.ms>
Reviewed by: -audit
MFC after: 1 week
2001-09-09 00:40:04 +00:00
Peter Wemm
c3aac50f28
$Id$ -> $FreeBSD$
1999-08-28 01:08:13 +00:00
Philippe Charnier
014927909d
Main() returns int.
1997-08-26 11:08:24 +00:00
Philippe Charnier
474cc7fe23
Was limited to 200 users. New entry is now allocated as needed.
...
Add usage().
Obtained from:OpenBSD.
1997-08-22 06:50:33 +00:00
Warner Losh
1c8af87873
compare return value from getopt against -1 rather than EOF, per the final
...
posix standard on the topic.
1997-03-29 04:34:07 +00:00
Rodney W. Grimes
9b50d90275
BSD 4.4 Lite Usr.bin Sources
1994-05-27 12:33:43 +00:00