From: David van Moolenbroek Date: Mon, 14 Dec 2009 20:25:52 +0000 (+0000) Subject: fix remaining warnings in 'make world' X-Git-Tag: v3.1.6~153 X-Git-Url: http://zhaoyanbai.com/repos/man.nsupdate.html?a=commitdiff_plain;h=d1918e2e9f4bba515f66607ca4b12ef2001afa4d;p=minix.git fix remaining warnings in 'make world' --- diff --git a/boot/rawfs.c b/boot/rawfs.c index 27b25c984..a143dc8ff 100644 --- a/boot/rawfs.c +++ b/boot/rawfs.c @@ -122,13 +122,13 @@ void r_stat(Ino_t inum, struct stat *stp) /* Fetch the block */ blockbuf = (union fsdata_u *) scratch; - readblock(block, blockbuf, block_size); + readblock(block, (char *) blockbuf, block_size); if (super.s_magic == SUPER_V2 || super.s_magic == SUPER_V3) { d2_inode *dip; int i; - dip= &blockbuf->b__v2_ino[ino_offset]; + dip= &blockbuf->b__v2_ino[(unsigned int) ino_offset]; curfil.i_mode= dip->d2_mode; curfil.i_nlinks= dip->d2_nlinks; @@ -144,7 +144,7 @@ void r_stat(Ino_t inum, struct stat *stp) d1_inode *dip; int i; - dip= &blockbuf->b__v1_ino[ino_offset]; + dip= &blockbuf->b__v1_ino[(unsigned int) ino_offset]; curfil.i_mode= dip->d1_mode; curfil.i_nlinks= dip->d1_nlinks; diff --git a/commands/elvis/curses.c b/commands/elvis/curses.c index cff84ebd4..e4b305bed 100644 --- a/commands/elvis/curses.c +++ b/commands/elvis/curses.c @@ -636,7 +636,7 @@ static void starttcap(term) * This function is called once during initialization, and thereafter it is * called whenever the SIGWINCH signal is sent to this process. */ -int getsize(signo) +void getsize(signo) int signo; { int lines; @@ -719,8 +719,6 @@ int getsize(signo) *o_columns = COLS; } #endif - - return 0; } diff --git a/commands/flex-2.5.4/Makefile.in b/commands/flex-2.5.4/Makefile.in index 4255d50c0..53d043d13 100644 --- a/commands/flex-2.5.4/Makefile.in +++ b/commands/flex-2.5.4/Makefile.in @@ -14,7 +14,7 @@ # For MS-DOS, add "-DMS_DOS" to DEFS. See the directory MISC/MSDOS for # additional info. -CFLAGS = @CFLAGS@ +CFLAGS = @CFLAGS@ -D_POSIX_SOURCE=1 CPPFLAGS = @CPPFLAGS@ DEFS = @DEFS@ LDFLAGS = @LDFLAGS@ diff --git a/commands/flex-2.5.4/initscan.c b/commands/flex-2.5.4/initscan.c index 381644dde..c7ca71757 100644 --- a/commands/flex-2.5.4/initscan.c +++ b/commands/flex-2.5.4/initscan.c @@ -1491,7 +1491,7 @@ YY_DECL int doing_codeblock = false; int i; - Char nmdef[MAXLINE], myesc(); + Char nmdef[MAXLINE]; #line 1498 "scan.c" @@ -2291,7 +2291,6 @@ YY_RULE_SETUP #line 435 "scan.l" { register Char *nmdefptr; - Char *ndlookup(); strcpy( nmstr, yytext + 1 ); nmstr[yyleng - 2] = '\0'; /* chop trailing brace */ diff --git a/commands/flex-2.5.4/libmain.c b/commands/flex-2.5.4/libmain.c index 3a5dabaab..909a23181 100644 --- a/commands/flex-2.5.4/libmain.c +++ b/commands/flex-2.5.4/libmain.c @@ -2,8 +2,12 @@ /* $Header$ */ +#include "flexdef.h" + extern int yylex(void); +int main PROTO((int, char**)); + int main( argc, argv ) int argc; char *argv[]; diff --git a/commands/flex-2.5.4/main.c b/commands/flex-2.5.4/main.c index 8ed002a9b..09d349987 100644 --- a/commands/flex-2.5.4/main.c +++ b/commands/flex-2.5.4/main.c @@ -43,6 +43,7 @@ static char flex_version[] = FLEX_VERSION; /* declare functions that have forward references */ +int main PROTO((int, char**)); void flexinit PROTO((int, char**)); void readin PROTO((void)); void set_up_initial_allocations PROTO((void)); diff --git a/commands/flex-2.5.4/scan.l b/commands/flex-2.5.4/scan.l index fee78ab75..dbd357963 100644 --- a/commands/flex-2.5.4/scan.l +++ b/commands/flex-2.5.4/scan.l @@ -98,7 +98,7 @@ LEXOPT [aceknopr] int doing_codeblock = false; int i; - Char nmdef[MAXLINE], myesc(); + Char nmdef[MAXLINE]; { @@ -434,7 +434,6 @@ LEXOPT [aceknopr] "{"{NAME}"}" { register Char *nmdefptr; - Char *ndlookup(); strcpy( nmstr, yytext + 1 ); nmstr[yyleng - 2] = '\0'; /* chop trailing brace */ diff --git a/commands/flex-2.5.4/sym.c b/commands/flex-2.5.4/sym.c index 326c9d3c5..d5c90fb0b 100644 --- a/commands/flex-2.5.4/sym.c +++ b/commands/flex-2.5.4/sym.c @@ -40,8 +40,6 @@ struct hash_entry *ndtbl[NAME_TABLE_HASH_SIZE]; struct hash_entry *sctbl[START_COND_HASH_SIZE]; struct hash_entry *ccltab[CCL_HASH_SIZE]; -struct hash_entry *findsym(); - /* addsym - add symbol and definitions to symbol table * @@ -105,7 +103,6 @@ int cclnum; /* We don't bother checking the return status because we are not * called unless the symbol is new. */ - Char *copy_unsigned_string(); (void) addsym( (char *) copy_unsigned_string( ccltxt ), (char *) 0, cclnum, @@ -179,8 +176,6 @@ void ndinstal( name, definition ) char name[]; Char definition[]; { - char *copy_string(); - Char *copy_unsigned_string(); if ( addsym( copy_string( name ), (char *) copy_unsigned_string( definition ), 0, @@ -227,7 +222,6 @@ void scinstal( str, xcluflg ) char str[]; int xcluflg; { - char *copy_string(); /* Generate start condition definition, for use in BEGIN et al. */ action_define( str, lastsc );