ed cb65a7fe02 Make our utmpx more like System V.
When booting the system, truncate the utx.active file, but do write the
BOOT_TIME record into it afterwards. This allows one to obtain the boot
time of the system as follows:

	struct utmpx u1 = { .ut_type = BOOT_TIME }, *u2;

	setutxent();
	u2 = getutxid(&u1);

Now, the boot time is stored in u2->ut_tv, just like on Linux and other
systems.

We don't open the utx.active file with O_EXLOCK. It's rather unlikely
that other applications use this database at the same time and I want to
prevent the possibility of deadlocks in init(8).

Discussed with:	pluknet
2011-10-27 17:05:18 +00:00
..
2011-06-18 13:56:33 +00:00
2011-10-27 17:05:18 +00:00
2011-09-27 17:54:10 +00:00
2011-07-10 06:57:00 +00:00
2011-03-01 11:47:51 +00:00