]> granicus.if.org Git - sudo/commitdiff
o Reorder some headers and use STDC_HEADERS define properly
authorTodd C. Miller <Todd.Miller@courtesan.com>
Fri, 14 Dec 2001 19:52:47 +0000 (19:52 +0000)
committerTodd C. Miller <Todd.Miller@courtesan.com>
Fri, 14 Dec 2001 19:52:47 +0000 (19:52 +0000)
o Update copyright year

getspwuid.c
goodpath.c
interfaces.c

index 0e4fa059d396089af4ef16304597c87d5ec57680..b67027baa3953f71cbce7ba69bc750c0e9cba075 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1996, 1998, 1999 Todd C. Miller <Todd.Miller@courtesan.com>
+ * Copyright (c) 1996, 1998-2001 Todd C. Miller <Todd.Miller@courtesan.com>
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
 
 #include "config.h"
 
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <sys/param.h>
 #include <stdio.h>
 #ifdef STDC_HEADERS
 # include <stdlib.h>
+# include <stddef.h>
+#else
+# ifdef HAVE_STDLIB_H
+#  include <stdlib.h>
+# endif
 #endif /* STDC_HEADERS */
 #ifdef HAVE_STRING_H
+# if defined(HAVE_MEMORY_H) && !defined(STDC_HEADERS)
+#  include <memory.h>
+# endif
 # include <string.h>
+#else
+# ifdef HAVE_STRINGS_H
+#  include <strings.h>
+# endif
 #endif /* HAVE_STRING_H */
-#ifdef HAVE_STRINGS_H
-# include <strings.h>
-#endif /* HAVE_STRINGS_H */
 #ifdef HAVE_UNISTD_H
 # include <unistd.h>
 #endif /* HAVE_UNISTD_H */
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <sys/param.h>
 #include <pwd.h>
 #ifdef HAVE_GETSPNAM
 # include <shadow.h>
index f950d944201a372a4c33a19967fe2a4efb2f74c8..10c5ec73ee391d2f7587c861d71f9618f87319d4 100644 (file)
@@ -1,6 +1,6 @@
 /*
- * Copyright (c) 1996, 1998, 1999 Todd C. Miller <Todd.Miller@courtesan.com>
- * All rights reserved.
+ * Copyright (c) 1996, 1998, 1999, 2001
+ *     Todd C. Miller <Todd.Miller@courtesan.com>.  All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions
 
 #include "config.h"
 
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <sys/param.h>
 #include <stdio.h>
-#ifdef HAVE_UNISTD_H
-#include <unistd.h>
-#endif /* HAVE_UNISTD_H */
 #ifdef HAVE_STRING_H
-#include <string.h>
+# include <string.h>
+#else
+# ifdef HAVE_STRINGS_H
+#  include <strings.h>
+# endif
 #endif /* HAVE_STRING_H */
-#ifdef HAVE_STRINGS_H
-#include <strings.h>
-#endif /* HAVE_STRINGS_H */
+#ifdef HAVE_UNISTD_H
+# include <unistd.h>
+#endif /* HAVE_UNISTD_H */
 #include <errno.h>
-#include <sys/types.h>
-#include <sys/stat.h>
-#include <sys/param.h>
 
 #include "sudo.h"
 
-#ifndef STDC_HEADERS
-extern int stat                __P((const char *, struct stat *));
-#endif /* !STDC_HEADERS */
-
 #ifndef lint
 static const char rcsid[] = "$Sudo$";
 #endif /* lint */
index b58a654d9b0808740d95678f2a7ff40e8091a532..7895c3291fa39333f9e6dfdd7b088e6cad237d28 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 1996, 1998, 1999 Todd C. Miller <Todd.Miller@courtesan.com>
+ * Copyright (c) 1996, 1998-2001 Todd C. Miller <Todd.Miller@courtesan.com>
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
@@ -43,47 +43,48 @@ struct rtentry;
 
 #include "config.h"
 
-#include <stdio.h>
-#ifdef STDC_HEADERS
-#include <stdlib.h>
-#endif /* STDC_HEADERS */
-#ifdef HAVE_UNISTD_H
-#include <unistd.h>
-#endif /* HAVE_UNISTD_H */
-#ifdef HAVE_STRING_H
-#include <string.h>
-#endif /* HAVE_STRING_H */
-#ifdef HAVE_STRINGS_H
-#include <strings.h>
-#endif /* HAVE_STRINGS_H */
-#include <netdb.h>
-#include <errno.h>
 #include <sys/types.h>
 #include <sys/socket.h>
 #include <sys/param.h>
 #include <sys/time.h>
 #include <sys/ioctl.h>
 #if defined(HAVE_SYS_SOCKIO_H) && !defined(SIOCGIFCONF)
-#include <sys/sockio.h>
+# include <sys/sockio.h>
 #endif
+#include <stdio.h>
+#ifdef HAVE_STRING_H
+# if defined(HAVE_MEMORY_H) && !defined(STDC_HEADERS)
+#  include <memory.h>
+# endif
+# include <string.h>
+#else
+# ifdef HAVE_STRINGS_H
+#  include <strings.h>
+# endif
+#endif /* HAVE_STRING_H */
+#ifdef HAVE_UNISTD_H
+# include <unistd.h>
+#endif /* HAVE_UNISTD_H */
+#include <netdb.h>
+#include <errno.h>
 #ifdef _ISC
-#include <sys/stream.h>
-#include <sys/sioctl.h>
-#include <sys/stropts.h>
-#include <net/errno.h>
-#define STRSET(cmd, param, len)        {strioctl.ic_cmd=(cmd);\
+# include <sys/stream.h>
+# include <sys/sioctl.h>
+# include <sys/stropts.h>
+# include <net/errno.h>
+# define STRSET(cmd, param, len) {strioctl.ic_cmd=(cmd);\
                                 strioctl.ic_dp=(param);\
                                 strioctl.ic_timout=0;\
                                 strioctl.ic_len=(len);}
 #endif /* _ISC */
 #ifdef _MIPS
-#include <net/soioctl.h>
+# include <net/soioctl.h>
 #endif /* _MIPS */
 #include <netinet/in.h>
 #include <arpa/inet.h>
 #include <net/if.h>
 #ifdef HAVE_GETIFADDRS
-#include <ifaddrs.h>
+# include <ifaddrs.h>
 #endif
 
 #include "sudo.h"