This is the mail archive of the libc-hacker@sources.redhat.com mailing list for the glibc project.
Note that libc-hacker is a closed list. You may look at the archives of this list, but subscription and posting are not open.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
This patch makes sure the getent program always prints a space between
the numeric address and the hostname. Makes the program somwhat more
usable in combination with IPv6 hosts.
Mark
2000-07-17 Mark Kettenis <kettenis@gnu.org>
* nss/getent.c (print_hosts): Make sure we always print a space
between numeric addresses and hostnames.
Index: nss/getent.c
===================================================================
RCS file: /cvs/glibc/libc/nss/getent.c,v
retrieving revision 1.4
diff -u -p -r1.4 getent.c
--- getent.c 2000/07/12 19:52:39 1.4
+++ getent.c 2000/07/17 10:11:54
@@ -257,8 +257,9 @@ print_hosts (struct hostent *host)
buf, sizeof (buf));
fputs (ip, stdout);
- for (i = strlen (ip); i < 16; ++i)
+ for (i = strlen (ip); i < 15; ++i)
fputs (" ", stdout);
+ fputs (" ", stdout);
fputs (host->h_name, stdout);
i = 0;
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |