diff options
author | Mats Erik Andersson <mats.andersson@gisladisker.se> | 2012-09-05 22:08:37 +0200 |
---|---|---|
committer | Eric Blake <eblake@redhat.com> | 2012-09-05 15:19:04 -0600 |
commit | 8a8ef57118fa76ee06d57715f997332a8d3488ec (patch) | |
tree | 4c90ea797f4bac6f8d47b6cdde80eff3b6cabb60 /modules/net_if | |
parent | 0815daf810f59e2da6778367a2000bdd25af71b4 (diff) | |
download | gnulib-8a8ef57118fa76ee06d57715f997332a8d3488ec.tar.gz |
readutmp: fix non-portable UT_PID use
The module readutmp is broken for the standard use
read_utmp(..., READ_UTMP_USER_PROCESS | READ_UTMP_CHECK_PIDS)
for all releases of FreeBSD until 8.3, and all OpenBSD ever released.
The reason is that those systems do not provide `utmp.ut_pid', thus
making the macro UT_PID(u) identical to naught, and then turning
the predicate
UT_PID (u) <= 0
found in desirable_utmp_entry(), into a permanent true clause.
This makes desirable_utmp_entry() discard every legitimate
user's UTMP entry for said BSD releases. NetBSD and DragonflyBSD
are not touched by this malfunction.
Copyright-paperwork-exempt: yes
* lib/readutmp.c (desirable_utmp_entry) <READ_UTMP_CHECK_PIDS>:
Use `UT_PID (u) > 0' as absolute condition.
Diffstat (limited to 'modules/net_if')
0 files changed, 0 insertions, 0 deletions