]> andersk Git - moira.git/commitdiff
strings.h -> string.h, the former doesn't exists on the sun now.
authorjweiss <jweiss>
Fri, 16 Sep 1994 22:01:55 +0000 (22:01 +0000)
committerjweiss <jweiss>
Fri, 16 Sep 1994 22:01:55 +0000 (22:01 +0000)
index -> strchr; POSIX, etc.

update/hostname.c

index 98e41c4bc4cae8071476bbd8a00e36599915cddb..1cb89e37fa04a8d5a9378539727a632102a3297a 100644 (file)
@@ -17,7 +17,7 @@ static char *rcsid_hostname_c = "$Header$";
 #include <netinet/in.h>
 #include <netdb.h>
 #include <ctype.h>
-#include <strings.h>
+#include <string.h>
 char *
 PrincipalHostname(alias)
      char *alias;
@@ -25,7 +25,7 @@ PrincipalHostname(alias)
      struct hostent *h;
      char *phost = alias;
      if ((h=gethostbyname(alias)) != (struct hostent *)NULL) {
-         char *p = index(h->h_name, '.');
+         char *p = strchr(h->h_name, '.');
          if (p)
               *p = NULL;
          p = phost = h->h_name;
This page took 0.046865 seconds and 5 git commands to generate.