projects
/
pspp
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
cd90feb
)
(desirable_utmp_entry): Fix bug where "who -b" and "who -r"
author
Paul Eggert
<eggert@cs.ucla.edu>
Wed, 22 Jun 2005 18:27:44 +0000
(18:27 +0000)
committer
Paul Eggert
<eggert@cs.ucla.edu>
Wed, 22 Jun 2005 18:27:44 +0000
(18:27 +0000)
failed to give output.
lib/ChangeLog
patch
|
blob
|
history
lib/readutmp.c
patch
|
blob
|
history
diff --git
a/lib/ChangeLog
b/lib/ChangeLog
index cffd88ee0531f189d01b922a6c0cad4486b97e88..3dd4580aa242debe0b4fd409c766b682c31daefb 100644
(file)
--- a/
lib/ChangeLog
+++ b/
lib/ChangeLog
@@
-1,5
+1,8
@@
2005-06-22 Paul Eggert <eggert@cs.ucla.edu>
+ * readutmp.c (desirable_utmp_entry): Fix bug where "who -b" and
+ "who -r" failed to give output. Problem reported by Tim Waugh.
+
* xmalloc.c (HAVE_GNU_CALLOC): New constant.
(xcalloc): Use it to avoid needless tests.
Problem reported by Jim Meyering.
diff --git
a/lib/readutmp.c
b/lib/readutmp.c
index ca4472c650a2994c06693678e3b1c39d608bf59c..846ab3c6a2da7103752ec757a18172697f880384 100644
(file)
--- a/
lib/readutmp.c
+++ b/
lib/readutmp.c
@@
-68,6
+68,7
@@
static inline bool
desirable_utmp_entry (STRUCT_UTMP const *u, int options)
{
return ! (options & READ_UTMP_CHECK_PIDS
+ && IS_USER_PROCESS (u)
&& (UT_PID (u) <= 0
|| (kill (UT_PID (u), 0) < 0 && errno == ESRCH)));
}