fix compiler warnings
git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@4565 e016b1c5-ed68-44aa-a2f7-31cac88cffde
This commit is contained in:
+4
-3
@@ -1,9 +1,10 @@
|
||||
CXXOPTFLAGS=-O3 -fomit-frame-pointer
|
||||
INCLUDES1=-I/usr/X11R6/include -I../enet/include -I../src
|
||||
INCLUDES2=`sdl-config --cflags`
|
||||
CXXCUSTOMFLAGS=-fsigned-char -Wall -Wno-deprecated -rdynamic
|
||||
CXXFLAGS=$(CXXOPTFLAGS) $(INCLUDES1) $(INCLUDES2) $(CUSTOMFLAGS)
|
||||
CXXFLAGSSERVER=$(CXXOPTFLAGS) $(INCLUDES1) $(CUSTOMFLAGS)
|
||||
#CXXCUSTOMFLAGS=-fsigned-char -Wall -Wextra -Wno-missing-field-initializers -Wno-unused -Wpointer-arith -Wconversion -rdynamic
|
||||
CXXCUSTOMFLAGS=-fsigned-char -Wall -Wconversion -rdynamic
|
||||
CXXFLAGS=$(CXXOPTFLAGS) $(INCLUDES1) $(INCLUDES2) $(CXXCUSTOMFLAGS)
|
||||
CXXFLAGSSERVER=$(CXXOPTFLAGS) $(INCLUDES1) $(CXXCUSTOMFLAGS)
|
||||
|
||||
PLATFORM_PREFIX=native
|
||||
CLIENT_LIBS=-L/usr/X11R6/lib -L../enet -lenet `sdl-config --libs` -lSDL_image -lz -lGL -lopenal -lvorbisfile -ljpeg
|
||||
|
||||
@@ -898,7 +898,7 @@ void receivefile(uchar *data, int len)
|
||||
int mapsize = getint(p);
|
||||
int cfgsize = getint(p);
|
||||
int cfgsizegz = getint(p);
|
||||
int revision = getint(p);
|
||||
/* int revision = */ getint(p);
|
||||
int size = mapsize + cfgsizegz;
|
||||
if(p.remaining() < size)
|
||||
{
|
||||
|
||||
+2
-2
@@ -382,9 +382,9 @@ public:
|
||||
vec head;
|
||||
|
||||
playerent() : clientnum(-1), lastupdate(0), plag(0), ping(0), lifesequence(0), frags(0), flagscore(0), deaths(0), lastpain(0), lastvoicecom(0), clientrole(CR_DEFAULT),
|
||||
skin(0), spectatemode(SM_NONE), followplayercn(-1), eardamagemillis(0), respawnoffset(0),
|
||||
team(0), skin(0), spectatemode(SM_NONE), followplayercn(-1), eardamagemillis(0), respawnoffset(0),
|
||||
prevweaponsel(NULL), weaponsel(NULL), nextweaponsel(NULL), primweap(NULL), nextprimweap(NULL), lastattackweapon(NULL),
|
||||
smoothmillis(-1), team(0),
|
||||
smoothmillis(-1),
|
||||
head(-1, -1, -1)
|
||||
{
|
||||
type = ENT_PLAYER;
|
||||
|
||||
@@ -2683,7 +2683,7 @@ void rereadcfgs(void)
|
||||
|
||||
void loggamestatus(const char *reason)
|
||||
{
|
||||
int fragscore[2] = {0, 0}, flagscore[2] = {0, 0}, pnum[2] = {0, 0}, n;
|
||||
int fragscore[2] = {0, 0}, flagscore[2] = {0, 0}, pnum[2] = {0, 0};
|
||||
string text;
|
||||
s_sprintf(text)("%d minutes remaining", minremain);
|
||||
logline(ACLOG_INFO, "");
|
||||
|
||||
@@ -80,10 +80,10 @@ struct mapaction : serveraction
|
||||
loopv(scl.adminonlymaps)
|
||||
{
|
||||
const char *s = scl.adminonlymaps[i], *h = strchr(s, '#'), *m = behindpath(map);
|
||||
int sl = strlen(s);
|
||||
size_t sl = strlen(s);
|
||||
if(h && h != s)
|
||||
{
|
||||
sl = (int) (h - s);
|
||||
sl = h - s;
|
||||
if(mode != atoi(h + 1)) continue;
|
||||
}
|
||||
if(sl == strlen(m) && !strncmp(m, scl.adminonlymaps[i], sl)) role = CR_ADMIN;
|
||||
|
||||
@@ -265,7 +265,7 @@ struct servermaprot : serverconfigfile
|
||||
|
||||
const char *sep = ": ";
|
||||
configset c;
|
||||
int i, numgood = 0, line = 0;
|
||||
int i, line = 0;
|
||||
char *l, *p = buf;
|
||||
logline(ACLOG_VERBOSE,"reading map rotation '%s'", filename);
|
||||
while(p < buf + filelen)
|
||||
|
||||
Reference in New Issue
Block a user