Skip to content

Commit

Permalink
add 'void' parameter declarations to those functions without anything
Browse files Browse the repository at this point in the history
  • Loading branch information
jonof committed Dec 2, 2023
1 parent 25652b0 commit 4034aa2
Show file tree
Hide file tree
Showing 7 changed files with 24 additions and 24 deletions.
2 changes: 1 addition & 1 deletion kenbuild/src/game.c
Original file line number Diff line number Diff line change
Expand Up @@ -6166,7 +6166,7 @@ int movesprite(short spritenum, int dx, int dy, int dz, int ceildist, int flordi
}


void waitforeverybody ()
void waitforeverybody (void)
{
int i;
if (numplayers < 2) return;
Expand Down
2 changes: 1 addition & 1 deletion src/a-c.c
Original file line number Diff line number Diff line change
Expand Up @@ -316,7 +316,7 @@ void stretchhline (void *p0, int u, int cnt, int uinc, void *rptr, void *p)
}


void mmxoverlay() { }
void mmxoverlay(void) { }

#endif
/*
Expand Down
10 changes: 5 additions & 5 deletions src/kplib.c
Original file line number Diff line number Diff line change
Expand Up @@ -385,7 +385,7 @@ static inline void cpuid (int a, int *s) { (void)a; (void)s; }

//Bit numbers of return value:
//0:FPU, 4:RDTSC, 15:CMOV, 22:MMX+, 23:MMX, 25:SSE, 26:SSE2, 30:3DNow!+, 31:3DNow!
static int getcputype ()
static int getcputype (void)
{
int i, cpb[4], cpid[4];
if (!testflag(0x200000)) return(0);
Expand All @@ -405,7 +405,7 @@ static int getcputype ()

static unsigned char fakebuf[8], *nfilptr;
static int nbitpos;
static void suckbitsnextblock ()
static void suckbitsnextblock (void)
{
int n;

Expand Down Expand Up @@ -522,7 +522,7 @@ static void hufgencode (int *inbuf, int inum, int *hitab, int *hbmax)
for(i=0;i<inum;i++) if (inbuf[i]) hitab[hbmax[inbuf[i]]++] = i;
}

static int initpass () //Interlaced images have 7 "passes", non-interlaced have 1
static int initpass (void) //Interlaced images have 7 "passes", non-interlaced have 1
{
int i, j, k;

Expand Down Expand Up @@ -981,7 +981,7 @@ static void putbuf (const unsigned char *buf, int leng)
}
}

static void initpngtables()
static void initpngtables(void)
{
int i, j, k;

Expand Down Expand Up @@ -1349,7 +1349,7 @@ static int cosqr16[8] = //cosqr16[i] = ((cos(PI*i/16)*sqrt(2))<<24);
{23726566,23270667,21920489,19727919,16777216,13181774,9079764,4628823};
static int crmul[4096], cbmul[4096];

static void initkpeg ()
static void initkpeg (void)
{
int i, x, y;

Expand Down
8 changes: 4 additions & 4 deletions src/mdsprite.c
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ static struct polymostvboitem *elementvbo = NULL; // 3 per triangle.
mdmodel *mdload (const char *);
void mdfree (mdmodel *);

void freeallmodels ()
void freeallmodels (void)
{
int i;

Expand Down Expand Up @@ -73,7 +73,7 @@ void freeallmodels ()

}

void clearskins ()
void clearskins (void)
{
mdmodel *m;
int i, j;
Expand Down Expand Up @@ -129,7 +129,7 @@ void clearskins ()
}
}

void mdinit ()
void mdinit (void)
{
memset(hudmem,0,sizeof(hudmem));
freeallmodels();
Expand Down Expand Up @@ -1437,7 +1437,7 @@ static int isolid (int x, int y, int z)
z += x*yzsiz + y*zsiz; return(vbit[z>>5]&(1<<SHIFTMOD32(z)));
}

static voxmodel *vox2poly ()
static voxmodel *vox2poly (void)
{
int i, j, x, y, z, v, ov, oz = 0, cnt, sc, x0, y0, dx, dy, *bx0, *by0;
void (*daquad)(int, int, int, int, int, int, int, int, int, int);
Expand Down
10 changes: 5 additions & 5 deletions src/mmulti.c
Original file line number Diff line number Diff line change
Expand Up @@ -565,14 +565,14 @@ static const char *presentaddress(struct sockaddr *a) {
unsigned char syncstate = 0;
void setpackettimeout (int datimeoutcount, int daresendagaincount) { (void)datimeoutcount; (void)daresendagaincount; }
void genericmultifunction (int other, unsigned char *bufptr, int messleng, int command) { (void)other; (void)bufptr; (void)messleng; (void)command; }
int getoutputcirclesize () { return(0); }
int getoutputcirclesize (void) { return(0); }
void setsocket (int newsocket) { (void)newsocket; }
void sendlogon () {}
void sendlogoff () {}
void sendlogon (void) {}
void sendlogoff (void) {}
//--------------------------------------------------------------------------------------------------

static int crctab16[256];
static void initcrc16 ()
static void initcrc16 (void)
{
int i, j, k, a;
for(j=0;j<256;j++)
Expand All @@ -595,7 +595,7 @@ static unsigned short getcrc16 (unsigned char *buffer, int bufleng)
return((unsigned short)(j&65535));
}

void uninitmultiplayers () { netuninit(); }
void uninitmultiplayers (void) { netuninit(); }

static void initmultiplayers_reset(void)
{
Expand Down
10 changes: 5 additions & 5 deletions src/polymost.c
Original file line number Diff line number Diff line change
Expand Up @@ -329,7 +329,7 @@ void polymost_texinvalidate (int dapicnum, int dapalnum, int dameth)
//Make all textures "dirty" so they reload, but not re-allocate
//This should be much faster than polymost_glreset()
//Use this for palette effects ... but not ones that change every frame!
void polymost_texinvalidateall ()
void polymost_texinvalidateall (void)
{
PTIter iter;
PTHead * pth;
Expand Down Expand Up @@ -421,7 +421,7 @@ float glox1, gloy1, glox2, gloy2;

//Use this for both initialization and uninitialization of OpenGL.
static int gltexcacnum = -1;
void polymost_glreset ()
void polymost_glreset (void)
{
//Reset if this is -1 (meaning 1st texture call ever), or > 0 (textures in memory)
if (gltexcacnum < 0)
Expand Down Expand Up @@ -683,7 +683,7 @@ static void polymost_loadshaders(void)
}

// one-time initialisation of OpenGL for polymost
void polymost_glinit()
void polymost_glinit(void)
{
glfunc.glClearColor(0,0,0,0.5); //Black Background
glfunc.glDisable(GL_DITHER);
Expand Down Expand Up @@ -2969,7 +2969,7 @@ static void polymost_scansector (int sectnum)
} while (sectorbordercnt > 0);
}

void polymost_drawrooms ()
void polymost_drawrooms (void)
{
int i, j, n, n2, closest;
double ox, oy, oz, ox2, oy2, oz2, r, px[6], py[6], pz[6], px2[6], py2[6], pz2[6], sx[6], sy[6];
Expand Down Expand Up @@ -4559,7 +4559,7 @@ static int polymost_preparetext(void)
return 0;
}

void polymost_precache_begin()
void polymost_precache_begin(void)
{
PTBeginPriming();
}
Expand Down
6 changes: 3 additions & 3 deletions src/polymosttex.c
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ static inline int ptm_gethashhead(const unsigned int idcrc)
return idcrc & (PTMHASHHEADSIZ-1);
}

static void detect_texture_size()
static void detect_texture_size(void)
{
if (gltexmaxsize <= 0) {
GLint siz = glinfo.maxtexsize;
Expand Down Expand Up @@ -1375,7 +1375,7 @@ int PTDoPrime(int* done, int* total)
/**
* Resets the texture hash but leaves the headers in memory
*/
void PTReset()
void PTReset(void)
{
PTHash * pth;
int i;
Expand All @@ -1392,7 +1392,7 @@ void PTReset()
/**
* Clears the texture hash of all content
*/
void PTClear()
void PTClear(void)
{
PTHash * pth, * next;
PTMHash * ptmh, * mnext;
Expand Down

0 comments on commit 4034aa2

Please sign in to comment.