From: Todd C. Miller Date: Mon, 8 Aug 1994 04:41:20 +0000 (+0000) Subject: ansi-fied !STDC_HEADER function prottypes X-Git-Tag: SUDO_1_3_1~31 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=e54f35e718efd4bdda9672746e31bb1401787fab;p=sudo ansi-fied !STDC_HEADER function prottypes --- diff --git a/find_path.c b/find_path.c index bde5578e2..9b3a9cee7 100644 --- a/find_path.c +++ b/find_path.c @@ -56,15 +56,15 @@ static char rcsid[] = "$Id$"; #include "sudo.h" #ifndef STDC_HEADERS -extern char *malloc __P((unsigned)); -extern char *getenv __P((char *)); -extern char *strcpy __P((char *, char *)); +extern char *malloc __P((size_t)); +extern char *getenv __P((const char *)); +extern char *strcpy __P((char *, const char *)); extern int fprintf __P((FILE *, const char *, ...)); -extern int readlink __P((char *, char *, int)); -extern int stat __P((char *, struct stat *)); -extern int lstat __P((char *, struct stat *)); +extern int readlink __P((const char *, char *, size_t)); +extern int stat __P((const char *, struct stat *)); +extern int lstat __P((const char *, struct stat *)); #ifdef HAVE_STRDUP -extern char *strdup __P((char *)); +extern char *strdup __P((const char *)); #endif /* HAVE_STRDUP */ #endif /* !STDC_HEADERS */ diff --git a/getcwd.c b/getcwd.c index b56c06f37..bcff9c24d 100644 --- a/getcwd.c +++ b/getcwd.c @@ -55,11 +55,11 @@ static char rcsid[] = "$Id$"; #include #ifndef STDC_HEADERS -extern char *strcpy __P((char *, char *)); -extern int strlen __P((char *)); +extern char *strcpy __P((char *, const char *)); +extern int strlen __P((const char *)); extern char *getwd __P((char *)); -extern char *malloc __P((unsigned)); -extern FILE *popen __P((char *, char *)); +extern char *malloc __P((size_t)); +extern FILE *popen __P((const char *, const char *)); extern int pclose __P((FILE *)); extern char *fgets __P((char *, int, FILE *)); #endif /* !STDC_HEADERS */ diff --git a/getwd.c b/getwd.c index b56c06f37..bcff9c24d 100644 --- a/getwd.c +++ b/getwd.c @@ -55,11 +55,11 @@ static char rcsid[] = "$Id$"; #include #ifndef STDC_HEADERS -extern char *strcpy __P((char *, char *)); -extern int strlen __P((char *)); +extern char *strcpy __P((char *, const char *)); +extern int strlen __P((const char *)); extern char *getwd __P((char *)); -extern char *malloc __P((unsigned)); -extern FILE *popen __P((char *, char *)); +extern char *malloc __P((size_t)); +extern FILE *popen __P((const char *, const char *)); extern int pclose __P((FILE *)); extern char *fgets __P((char *, int, FILE *)); #endif /* !STDC_HEADERS */ diff --git a/putenv.c b/putenv.c index 3136e2f3f..8d18e0217 100644 --- a/putenv.c +++ b/putenv.c @@ -47,7 +47,7 @@ static char rcsid[] = "$Id$"; #include #ifndef STDC_HEADERS -extern char *malloc __P((unsigned)); +extern char *malloc __P((size_t)); #endif /* !STDC_HEADERS */ diff --git a/strdup.c b/strdup.c index 395f064c1..c02e44fa8 100644 --- a/strdup.c +++ b/strdup.c @@ -53,8 +53,8 @@ static char rcsid[] = "$Id$"; #endif /* HAVE_MALLOC_H */ #ifndef STDC_HEADERS -extern char *malloc __P((unsigned)); -extern char *strcpy __P((char *, char *)); +extern char *malloc __P((size_t)); +extern char *strcpy __P((char *, const char *)); #endif /* !STDC_HEADERS */ diff --git a/sudo.c b/sudo.c index 5bfc749a0..14b825f20 100644 --- a/sudo.c +++ b/sudo.c @@ -85,9 +85,9 @@ static char rcsid[] = "$Id$"; #include "version.h" #ifndef STDC_HEADERS -extern char *malloc __P((unsigned)); +extern char *malloc __P((size_t)); #ifdef HAVE_STRDUP -extern char *strdup __P((char *)); +extern char *strdup __P((const char *)); #endif /* HAVE_STRDUP */ #endif /* STDC_HEADERS */ diff --git a/sudo_realpath.c b/sudo_realpath.c index 9666c92e6..f53c03eba 100644 --- a/sudo_realpath.c +++ b/sudo_realpath.c @@ -53,9 +53,9 @@ static char rcsid[] = "$Id$"; #include "sudo.h" #ifndef STDC_HEADERS -extern char *strcpy __P((char *, char *)); -extern int readlink __P((char *, char *, int)); -extern int lstat __P((char *, struct stat *)); +extern char *strcpy __P((char *, const char *)); +extern int readlink __P((const char *, char *, size_t)); +extern int lstat __P((const char *, struct stat *)); #endif /* !STDC_HEADERS */ diff --git a/sudo_setenv.c b/sudo_setenv.c index 17087a801..a046be137 100644 --- a/sudo_setenv.c +++ b/sudo_setenv.c @@ -44,10 +44,10 @@ static char rcsid[] = "$Id$"; #ifndef STDC_HEADERS #ifdef HAVE_PUTENV -extern int putenv(); +extern int putenv __P((const char *)); #endif /* HAVE_PUTENV */ #ifdef HAVE_SETENV -extern int setenv(); +extern int setenv __P((char *, char *, int)); #endif /* HAVE_SETENV */ #endif /* !STDC_HEADERS */