Super-Rogue: convert to ANSI-style function declarations.
This fixes most of the build warnings.
This commit is contained in:
parent
0f87d5b4d8
commit
59f448e92e
33 changed files with 783 additions and 518 deletions
|
|
@ -34,14 +34,14 @@
|
|||
|
||||
#include "rogue.ext"
|
||||
|
||||
char *roguehome(void);
|
||||
void open_records(void);
|
||||
|
||||
extern int scorefd;
|
||||
extern FILE *logfile;
|
||||
|
||||
main(argc, argv, envp)
|
||||
char **argv;
|
||||
char **envp;
|
||||
int
|
||||
main(int argc, char *argv[], char *envp[])
|
||||
{
|
||||
register char *env;
|
||||
register struct linked_list *item;
|
||||
|
|
@ -50,7 +50,6 @@ char **envp;
|
|||
char *getpass(), *xcrypt(), *strrchr();
|
||||
int lowtime;
|
||||
time_t now;
|
||||
char *roguehome();
|
||||
char *homedir = roguehome();
|
||||
|
||||
#ifdef __DJGPP__
|
||||
|
|
@ -322,8 +321,8 @@ endit(int a)
|
|||
* Exit the program, printing a message.
|
||||
*/
|
||||
|
||||
fatal(s)
|
||||
char *s;
|
||||
void
|
||||
fatal(char *s)
|
||||
{
|
||||
clear();
|
||||
refresh();
|
||||
|
|
@ -340,8 +339,7 @@ char *s;
|
|||
*/
|
||||
|
||||
void
|
||||
byebye(how)
|
||||
int how;
|
||||
byebye(int how)
|
||||
{
|
||||
if (!isendwin())
|
||||
endwin();
|
||||
|
|
@ -354,8 +352,8 @@ int how;
|
|||
* rnd:
|
||||
* Pick a very random number.
|
||||
*/
|
||||
rnd(range)
|
||||
int range;
|
||||
int
|
||||
rnd(int range)
|
||||
{
|
||||
reg int wh;
|
||||
|
||||
|
|
@ -372,8 +370,8 @@ int range;
|
|||
* roll:
|
||||
* roll a number of dice
|
||||
*/
|
||||
roll(number, sides)
|
||||
int number, sides;
|
||||
int
|
||||
roll(int number, int sides)
|
||||
{
|
||||
reg int dtotal = 0;
|
||||
|
||||
|
|
@ -386,7 +384,8 @@ int number, sides;
|
|||
/*
|
||||
** setup: Setup signal catching functions
|
||||
*/
|
||||
setup()
|
||||
void
|
||||
setup(void)
|
||||
{
|
||||
md_onsignal_autosave();
|
||||
|
||||
|
|
@ -400,7 +399,8 @@ setup()
|
|||
** refreshing things and looking at the proper times.
|
||||
*/
|
||||
|
||||
playit()
|
||||
void
|
||||
playit(void)
|
||||
{
|
||||
reg char *opts;
|
||||
|
||||
|
|
@ -421,7 +421,8 @@ playit()
|
|||
/*
|
||||
** author: See if a user is an author of the program
|
||||
*/
|
||||
author()
|
||||
bool
|
||||
author(void)
|
||||
{
|
||||
switch (playuid) {
|
||||
case 100:
|
||||
|
|
@ -444,7 +445,7 @@ directory_exists(char *dirname)
|
|||
}
|
||||
|
||||
char *
|
||||
roguehome()
|
||||
roguehome(void)
|
||||
{
|
||||
static char path[LINLEN+16];
|
||||
char *end,*home;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue