summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>1996-02-23 16:12:01 +0000
committerJim Meyering <jim@meyering.net>1996-02-23 16:12:01 +0000
commit9cb56e2980b6ee30d982c18a84ea7723e7849318 (patch)
tree7c510b6810c40fe5fa68e3ae68760579f5e08390
parentc5134a9b1328e446181fd0f8bd44c160cdb526c7 (diff)
downloadcoreutils-9cb56e2980b6ee30d982c18a84ea7723e7849318.tar.xz
(print_entry): Use strchr, not index.
-rw-r--r--src/who-users.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/who-users.c b/src/who-users.c
index ce9553c72..47298dcc0 100644
--- a/src/who-users.c
+++ b/src/who-users.c
@@ -255,7 +255,7 @@ print_entry (struct utmp *this)
ut_host[sizeof (this->ut_host)] = '\0';
/* Look for an X display. */
- display = index (ut_host, ':');
+ display = strrchr (ut_host, ':');
if (display)
*display++ = '\0';