aboutsummaryrefslogtreecommitdiff
path: root/lib/libc
diff options
context:
space:
mode:
authorCraig Rodrigues <rodrigc@FreeBSD.org>2015-09-20 20:28:49 +0000
committerCraig Rodrigues <rodrigc@FreeBSD.org>2015-09-20 20:28:49 +0000
commit25070501c638474bf35d30c744d449fdfee787e7 (patch)
tree996688ef2df5a8bbdf03a5f32369cbfdcb9783eb /lib/libc
parent4178e4b07056ecaec180ad346f73624b68f2d977 (diff)
downloadsrc-25070501c638474bf35d30c744d449fdfee787e7.tar.gz
src-25070501c638474bf35d30c744d449fdfee787e7.zip
Use ANSI C prototypes. Eliminates -Wold-style-definition warnings.
Notes
Notes: svn path=/head/; revision=288033
Diffstat (limited to 'lib/libc')
-rw-r--r--lib/libc/stdio/findfp.c8
-rw-r--r--lib/libc/stdio/getchar.c2
-rw-r--r--lib/libc/stdio/vfscanf.c4
3 files changed, 6 insertions, 8 deletions
diff --git a/lib/libc/stdio/findfp.c b/lib/libc/stdio/findfp.c
index 8dc8053c62d7..0eabe82d753f 100644
--- a/lib/libc/stdio/findfp.c
+++ b/lib/libc/stdio/findfp.c
@@ -113,7 +113,7 @@ moreglue(int n)
* Find a free FILE for fopen et al.
*/
FILE *
-__sfp()
+__sfp(void)
{
FILE *fp;
int n;
@@ -164,7 +164,7 @@ found:
*/
__warn_references(f_prealloc,
"warning: this program uses f_prealloc(), which is not recommended.");
-void f_prealloc_void();
+void f_prealloc(void);
void
f_prealloc(void)
@@ -196,7 +196,7 @@ f_prealloc(void)
* The name `_cleanup' is, alas, fairly well known outside stdio.
*/
void
-_cleanup()
+_cleanup(void)
{
/* (void) _fwalk(fclose); */
(void) _fwalk(__sflush); /* `cheating' */
@@ -206,7 +206,7 @@ _cleanup()
* __sinit() is called whenever stdio's internal variables must be set up.
*/
void
-__sinit()
+__sinit(void)
{
/* Make sure we clean up on exit. */
diff --git a/lib/libc/stdio/getchar.c b/lib/libc/stdio/getchar.c
index 21040bc8c416..2815072f866e 100644
--- a/lib/libc/stdio/getchar.c
+++ b/lib/libc/stdio/getchar.c
@@ -49,7 +49,7 @@ __FBSDID("$FreeBSD$");
#undef getchar_unlocked
int
-getchar()
+getchar(void)
{
int retval;
FLOCKFILE(stdin);
diff --git a/lib/libc/stdio/vfscanf.c b/lib/libc/stdio/vfscanf.c
index 50f0690b6678..b5372631840b 100644
--- a/lib/libc/stdio/vfscanf.c
+++ b/lib/libc/stdio/vfscanf.c
@@ -814,9 +814,7 @@ match_failure:
* considered part of the scanset.
*/
static const u_char *
-__sccl(tab, fmt)
- char *tab;
- const u_char *fmt;
+__sccl(char *tab, const u_char *fmt)
{
int c, n, v, i;
struct xlocale_collate *table =