add ANSI C prototypes
authorKeith Bostic <bostic@ucbvax.Berkeley.EDU>
Wed, 7 Mar 1990 09:04:34 +0000 (01:04 -0800)
committerKeith Bostic <bostic@ucbvax.Berkeley.EDU>
Wed, 7 Mar 1990 09:04:34 +0000 (01:04 -0800)
SCCS-vsn: include/strings.h 5.7
SCCS-vsn: include/time.h 5.2
SCCS-vsn: include/ttyent.h 5.3
SCCS-vsn: include/dirent.h 5.8

usr/src/include/dirent.h
usr/src/include/strings.h
usr/src/include/time.h
usr/src/include/ttyent.h

index c72440d..420613f 100644 (file)
@@ -14,7 +14,7 @@
  * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
  * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  *
  * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
  * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  *
- *     @(#)dirent.h    5.7 (Berkeley) %G%
+ *     @(#)dirent.h    5.8 (Berkeley) %G%
  */
 
 #ifndef _DIRENT_
  */
 
 #ifndef _DIRENT_
@@ -60,13 +60,28 @@ typedef struct _dirdesc {
 #ifndef NULL
 #define NULL 0
 #endif
 #ifndef NULL
 #define NULL 0
 #endif
-extern DIR *opendir();
-extern struct dirent *readdir();
-extern long telldir();
-extern void seekdir();
-extern void closedir();
+
 extern long _rewinddir;
 #define rewinddir(dirp) \
        _seekdir((dirp), _rewinddir), \
        _rewinddir = telldir(dirp)
 extern long _rewinddir;
 #define rewinddir(dirp) \
        _seekdir((dirp), _rewinddir), \
        _rewinddir = telldir(dirp)
+
+#ifdef __STDC__
+extern DIR *opendir(const char *);
+extern struct dirent *readdir(DIR *);
+extern long telldir(const DIR *);
+extern void seekdir(DIR *, long);
+extern void closedir(DIR *);
+extern int scandir(const char *, struct direct *(*[]),
+    int (* )(struct direct *), int (* )(char *, char *));
+extern int alphasort(const struct direct **, const struct direct **);
+#else
+extern DIR *opendir();
+extern struct dirent *readdir();
+extern long telldir();
+extern void seekdir();
+extern void closedir();
+extern int scandir();
+extern int alphasort();
+#endif
 #endif /* _DIRENT_ */
 #endif /* _DIRENT_ */
index e8a2be0..c09dff6 100644 (file)
  * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
  * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  *
  * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
  * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  *
- *     @(#)strings.h   5.6 (Berkeley) %G%
+ *     @(#)strings.h   5.7 (Berkeley) %G%
  */
 
  */
 
-/* Routines described in string(3) */
-char   *strcat(), *strncat(), *strcpy(), *strncpy(), *index(), *rindex();
-int    strcmp(), strncmp(), strcasecmp(), strncasecmp(), strlen();
-
-/* Routines described in memory(BA_LIB); System V compatibility */
-char   *memccpy(), *memchr(), *memcpy(), *memset(), *strchr(),
-       *strdup(), *strpbrk(), *strrchr(), *strsep(), *strtok();
-int    memcmp(), strcspn(), strspn();
-
-/* Routines from ANSI X3J11 */
-char   *strerror();
+#ifdef __STDC__
+extern int memcmp(const char *, const char *, int);
+extern int strcasecmp(const char *, const char *);
+extern int strcmp(const char *, const char *);
+extern int strcspn(const char *, const char *);
+extern int strlen(const char *);
+extern int strncasecmp(const char *, const char *, int);
+extern int strncmp(const char *, const char *, int);
+extern int strspn(const char *, const char *);
+extern char *index(const char *, int);
+extern char *memccpy(char *, const char *, int, int);
+extern char *memchr(const char *, int, int);
+extern char *memcpy(char *, const char *, int);
+extern char *memset(char *, int, int);
+extern char *rindex(const char *, int);
+extern char *strcat(char *, const char *);
+extern char *strchr(const char *, int);
+extern char *strcpy(char *, const char *);
+extern char *strdup(const char *);
+extern char *strerror(int);
+extern char *strncat(char *, const char *, int);
+extern char *strncpy(char *, const char *, int);
+extern char *strpbrk(const char *, const char *);
+extern char *strrchr(const char *, int);
+extern char *strsep(char *, const char *);
+extern char *strtok(char *, const char *);
+#else
+extern int memcmp();
+extern int strcasecmp();
+extern int strcmp();
+extern int strcspn();
+extern int strlen();
+extern int strncasecmp();
+extern int strncmp();
+extern int strspn();
+extern char *index();
+extern char *memccpy();
+extern char *memchr();
+extern char *memcpy();
+extern char *memset();
+extern char *rindex();
+extern char *strcat();
+extern char *strchr();
+extern char *strcpy();
+extern char *strdup();
+extern char *strerror();
+extern char *strncat();
+extern char *strncpy();
+extern char *strpbrk();
+extern char *strrchr();
+extern char *strsep();
+extern char *strtok();
+#endif
index a628efd..fee7b0a 100644 (file)
@@ -14,7 +14,7 @@
  * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
  * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  *
  * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
  * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  *
- *     @(#)time.h      5.1 (Berkeley) %G%
+ *     @(#)time.h      5.2 (Berkeley) %G%
  */
 
 struct tm {
  */
 
 struct tm {
@@ -31,6 +31,26 @@ struct tm {
        char    *tm_zone;       /* timezone abbreviation */
 };
 
        char    *tm_zone;       /* timezone abbreviation */
 };
 
-void tzset();
-struct tm *gmtime(), *localtime();
-char *asctime(), *ctime(), *timezone();
+#ifdef __STDC__
+extern struct tm *gmtime(const time_t *);
+extern struct tm *localtime(const time_t *);
+extern time_t mktime(const struct tm *);
+extern time_t time(time_t *);
+extern double difftime(const time_t, const time_t);
+extern char *asctime(const struct tm *);
+extern char *ctime(const time_t *);
+extern char *timezone(int , int);
+extern void tzset(void);
+extern void tzsetwall(void);
+#else
+extern struct tm *gmtime();
+extern struct tm *localtime();
+extern time_t mktime();
+extern time_t time();
+extern double difftime();
+extern char *asctime();
+extern char *ctime();
+extern char *timezone();
+extern void tzset();
+extern void tzsetwall();
+#endif 
index 3da3f4b..3923f81 100644 (file)
@@ -14,7 +14,7 @@
  * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
  * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  *
  * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
  * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  *
- *     @(#)ttyent.h    5.2 (Berkeley) %G%
+ *     @(#)ttyent.h    5.3 (Berkeley) %G%
  */
 
 #define        _PATH_TTYS      "/etc/ttys"
  */
 
 #define        _PATH_TTYS      "/etc/ttys"
@@ -35,4 +35,14 @@ struct ttyent {
        char    *ty_comment;    /* comment field */
 };
 
        char    *ty_comment;    /* comment field */
 };
 
-extern struct ttyent *getttyent(), *getttynam();
+#ifdef __STDC__
+extern struct ttyent *getttyent(void);
+extern struct ttyent *getttynam(const char *);
+extern int setttyent(void);
+extern int endttyent(void);
+#else
+extern struct ttyent *getttyent();
+extern struct ttyent *getttynam();
+extern int setttyent();
+extern int endttyent();
+#endif