Commit Graph

19 Commits

Author SHA1 Message Date
Mark Murray
547fa0d9b7 ANSIfy, WARNSify, CONSTify. Bit of style(9)-ify. 2003-10-18 10:04:16 +00:00
Peter Wemm
f316609eb4 Oops. Some ut_time stuff slipped through the cracks. These turned out
to be non-fatal due to stack alignment roundups.
2002-11-17 23:46:45 +00:00
Bruce Evans
3798cf8a70 #include <time.h> for the definition of time functions instead of
depending on namespace pollution 2 layers deep in <sys/stat.h>.

Sorted includes.
2002-02-25 12:02:03 +00:00
Matthew Dillon
8719c58fef Add __FBSDID()s to libutil 2001-09-30 22:35:07 +00:00
Brian Somers
c61b512ccc Move trimdomain() into it's own source file and tidy things up a bit.
Fix disorder in the Makefile.

Reviewed (mostly) by: bde
2001-03-14 20:51:15 +00:00
Yoshinobu Inoue
ad5e523b7f Support v6 login. 2000-01-15 03:26:54 +00:00
Peter Wemm
7f3dea244c $Id$ -> $FreeBSD$ 1999-08-28 00:22:10 +00:00
Brian Somers
d746fb6643 If given host.domain:nn[.nn], trimdomain() now reduces it to
host:nn[.nn] (if the domain is the same as the local one).
1999-04-09 01:54:10 +00:00
Brian Somers
c1df83d996 bcopy -> memmove
Suggested by: archie
1999-04-08 08:00:06 +00:00
Brian Somers
0c059599f6 Tidy up trimdomain() and document it.
Don't truncate one byte short of the passed length.
1999-04-07 14:03:31 +00:00
Brian Somers
5b3f0a74e1 Handle hostnames up to MAXHOSTNAMELEN-1 in length.
Use bcopy() instead of strcpy() to handle potentially
overlapping regions.
Un-obscure/complicate some code.
1999-04-07 08:27:04 +00:00
Jordan K. Hubbard
8b1ef8d464 Now take stdio.h out of files that don't require it. 1998-10-09 11:24:20 +00:00
Jordan K. Hubbard
b8c11ec197 All these have to include stdio.h now. 1998-10-09 00:39:09 +00:00
Atsushi Murai
89caae2932 Trim a domain part for wtmp as same as showed by "netstat -r".
Here is a some example for avoiding a confusion.

 It asssumes a logged host domain is "spec.co.jp". All
example is longer than UT_HOSTNAMELEN value.

   1) turbo.tama.spec.co.jp: 192.19.0.2  -> trubo.tama
   2) turbo.tama.foo.co.jp : 192.19.0.2  -> 192.19.0.2
   3) specgw.spec.co.jp    : 202.32.13.1 -> specgw

Submitted by:	Atsushi Murai <amurai@spec.co.jp>
1998-06-01 08:47:04 +00:00
Paul Traina
326df44ead The parameters to logwtmp should be const char's 1997-09-04 22:38:59 +00:00
Steve Price
673b794638 Protect the copyright comments from reformatting by
indent and make this compile -Wall clean like the
Makefile suggests that it should. :)

Pointed out by:	Bruce Evans <bde@zeta.org.au>
1997-08-13 20:42:18 +00:00
Andrey A. Chernov
2fcdb74d96 If hostname > UT_HOSTSIZE, use its numeric address instead to keep
valid entries into utmp and wtmp
1996-06-17 14:49:02 +00:00
Peter Wemm
3b7e1cc80f Bump libutil revision after recent addition of setproctitle().
Install (optional) libutil.h with prototypes for the functions and
document this in the man page.

minor cleanups to the various routines, include the prototype file, declare
return codes etc.
1996-01-01 08:27:41 +00:00
Rodney W. Grimes
58f0484fa2 BSD 4.4 Lite Lib Sources 1994-05-27 05:00:24 +00:00