summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorjraynard <jraynard@FreeBSD.org>1996-06-12 22:58:21 +0000
committerjraynard <jraynard@FreeBSD.org>1996-06-12 22:58:21 +0000
commit4a395602dc927c2e081ae681cefecd87fe5ca3b1 (patch)
treecd51d1f651327a263425cb2b525df325e4f67dfa /lib
parent8a4400a463b6e76c6c1aebcd4a04d44c0275288c (diff)
downloadFreeBSD-src-4a395602dc927c2e081ae681cefecd87fe5ca3b1.zip
FreeBSD-src-4a395602dc927c2e081ae681cefecd87fe5ca3b1.tar.gz
Code cleanup:-
The usual stuff, adding missing function prototypes, argument types, return values, etc. In mktemp.c, convert pid from u_int to pid_t, and get rid of "extern int errno".
Diffstat (limited to 'lib')
-rw-r--r--lib/libc/stdio/fsetpos.c2
-rw-r--r--lib/libc/stdio/fvwrite.c2
-rw-r--r--lib/libc/stdio/fwalk.c2
-rw-r--r--lib/libc/stdio/getw.c2
-rw-r--r--lib/libc/stdio/mktemp.c9
-rw-r--r--lib/libc/stdio/printf.c2
-rw-r--r--lib/libc/stdio/refill.c4
7 files changed, 11 insertions, 12 deletions
diff --git a/lib/libc/stdio/fsetpos.c b/lib/libc/stdio/fsetpos.c
index 4dace2d..23faf26 100644
--- a/lib/libc/stdio/fsetpos.c
+++ b/lib/libc/stdio/fsetpos.c
@@ -43,7 +43,7 @@ static char sccsid[] = "@(#)fsetpos.c 8.1 (Berkeley) 6/4/93";
/*
* fsetpos: like fseek.
*/
-fsetpos(iop, pos)
+int fsetpos(iop, pos)
FILE *iop;
const fpos_t *pos;
{
diff --git a/lib/libc/stdio/fvwrite.c b/lib/libc/stdio/fvwrite.c
index 3ab6279..38ddc9e 100644
--- a/lib/libc/stdio/fvwrite.c
+++ b/lib/libc/stdio/fvwrite.c
@@ -49,7 +49,7 @@ static char sccsid[] = "@(#)fvwrite.c 8.1 (Berkeley) 6/4/93";
* This routine is large and unsightly, but most of the ugliness due
* to the three different kinds of output buffering is handled here.
*/
-__sfvwrite(fp, uio)
+int __sfvwrite(fp, uio)
register FILE *fp;
register struct __suio *uio;
{
diff --git a/lib/libc/stdio/fwalk.c b/lib/libc/stdio/fwalk.c
index 7771c41..2e19d3e 100644
--- a/lib/libc/stdio/fwalk.c
+++ b/lib/libc/stdio/fwalk.c
@@ -43,7 +43,7 @@ static char sccsid[] = "@(#)fwalk.c 8.1 (Berkeley) 6/4/93";
#include "local.h"
#include "glue.h"
-_fwalk(function)
+int _fwalk(function)
register int (*function)();
{
register FILE *fp;
diff --git a/lib/libc/stdio/getw.c b/lib/libc/stdio/getw.c
index 5220290..0053391 100644
--- a/lib/libc/stdio/getw.c
+++ b/lib/libc/stdio/getw.c
@@ -40,7 +40,7 @@ static char sccsid[] = "@(#)getw.c 8.1 (Berkeley) 6/4/93";
#include <stdio.h>
-getw(fp)
+int getw(fp)
FILE *fp;
{
int x;
diff --git a/lib/libc/stdio/mktemp.c b/lib/libc/stdio/mktemp.c
index 3f5966e..afe3f2d 100644
--- a/lib/libc/stdio/mktemp.c
+++ b/lib/libc/stdio/mktemp.c
@@ -43,9 +43,9 @@ static char sccsid[] = "@(#)mktemp.c 8.1 (Berkeley) 6/4/93";
#include <unistd.h>
#include <ctype.h>
-static int _gettemp();
+static int _gettemp(char *, int *);
-mkstemp(path)
+int mkstemp(path)
char *path;
{
int fd;
@@ -61,14 +61,13 @@ mktemp(path)
}
static
-_gettemp(path, doopen)
+int _gettemp(path, doopen)
char *path;
register int *doopen;
{
- extern int errno;
register char *start, *trv;
struct stat sbuf;
- u_int pid;
+ pid_t pid;
pid = getpid();
for (trv = path; *trv; ++trv); /* extra X's get set to 0's */
diff --git a/lib/libc/stdio/printf.c b/lib/libc/stdio/printf.c
index eb6ae83..64ea6b0 100644
--- a/lib/libc/stdio/printf.c
+++ b/lib/libc/stdio/printf.c
@@ -46,7 +46,7 @@ static char sccsid[] = "@(#)printf.c 8.1 (Berkeley) 6/4/93";
#endif
#if __STDC__
-printf(char const *fmt, ...)
+int printf(char const *fmt, ...)
#else
printf(fmt, va_alist)
char *fmt;
diff --git a/lib/libc/stdio/refill.c b/lib/libc/stdio/refill.c
index 35af0c0..8b118d6 100644
--- a/lib/libc/stdio/refill.c
+++ b/lib/libc/stdio/refill.c
@@ -44,7 +44,7 @@ static char sccsid[] = "@(#)refill.c 8.1 (Berkeley) 6/4/93";
#include "local.h"
static
-lflush(fp)
+int lflush(fp)
FILE *fp;
{
@@ -57,7 +57,7 @@ lflush(fp)
* Refill a stdio buffer.
* Return EOF on eof or error, 0 otherwise.
*/
-__srefill(fp)
+int __srefill(fp)
register FILE *fp;
{
OpenPOWER on IntegriCloud