From bf4ab34b0aeb68932c4a1c0e6505ab07917fa93b Mon Sep 17 00:00:00 2001 From: Rudolf Polzer Date: Sun, 5 Jun 2011 19:47:08 +0200 Subject: [PATCH] more warnings done. Now q3map2 is warning free apart from libpng deprecation problems. --- libs/picomodel/lwo/lwo2.c | 4 ++-- libs/picomodel/lwo/lwob.c | 4 ++-- libs/picomodel/pm_fm.c | 2 -- libs/picomodel/pm_md2.c | 2 -- tools/quake3/common/imagelib.c | 3 +-- tools/quake3/common/scriplib.c | 3 +-- 6 files changed, 6 insertions(+), 12 deletions(-) diff --git a/libs/picomodel/lwo/lwo2.c b/libs/picomodel/lwo/lwo2.c index 56c756c..9e45bfa 100644 --- a/libs/picomodel/lwo/lwo2.c +++ b/libs/picomodel/lwo/lwo2.c @@ -272,7 +272,7 @@ Fail: int lwValidateObject( const char *filename, picoMemStream_t *fp, unsigned int *failID, int *failpos ) { - unsigned int id, formsize, type; + unsigned int id, type; /* open the file */ @@ -282,7 +282,7 @@ int lwValidateObject( const char *filename, picoMemStream_t *fp, unsigned int *f set_flen( 0 ); id = getU4( fp ); - formsize = getU4( fp ); + /* formsize = */ getU4( fp ); type = getU4( fp ); if ( 12 != get_flen() ) { return PICO_PMV_ERROR_SIZE; diff --git a/libs/picomodel/lwo/lwob.c b/libs/picomodel/lwo/lwob.c index f12e3a3..cb2a70e 100644 --- a/libs/picomodel/lwo/lwob.c +++ b/libs/picomodel/lwo/lwob.c @@ -712,7 +712,7 @@ Fail: int lwValidateObject5( const char *filename, picoMemStream_t *fp, unsigned int *failID, int *failpos ) { - unsigned int id, formsize, type; + unsigned int id, type; /* open the file */ @@ -723,7 +723,7 @@ int lwValidateObject5( const char *filename, picoMemStream_t *fp, unsigned int * set_flen( 0 ); id = getU4( fp ); - formsize = getU4( fp ); + /* formsize = */ getU4( fp ); type = getU4( fp ); if ( 12 != get_flen() ) { return PICO_PMV_ERROR_SIZE; diff --git a/libs/picomodel/pm_fm.c b/libs/picomodel/pm_fm.c index 1065160..0fc6581 100644 --- a/libs/picomodel/pm_fm.c +++ b/libs/picomodel/pm_fm.c @@ -208,7 +208,6 @@ static picoModel_t *_fm_load( PM_PARAMS_LOAD ) { int i, j, dups, dup_index; int fm_file_pos; - short tot_numVerts; index_LUT_t *p_index_LUT, *p_index_LUT2, *p_index_LUT3; index_DUP_LUT_t *p_index_LUT_DUPS; @@ -458,7 +457,6 @@ static picoModel_t *_fm_load( PM_PARAMS_LOAD ) } // Fill in Look Up Table, and allocate/fill Linked List from vert array as needed for dup STs per Vert. - tot_numVerts = fm_head->numXYZ; dups = 0; triangle = tri_verts; diff --git a/libs/picomodel/pm_md2.c b/libs/picomodel/pm_md2.c index d53f702..19b5689 100644 --- a/libs/picomodel/pm_md2.c +++ b/libs/picomodel/pm_md2.c @@ -329,7 +329,6 @@ static int _md2_canload( PM_PARAMS_CANLOAD ) static picoModel_t *_md2_load( PM_PARAMS_LOAD ) { int i, j, dups, dup_index; - short tot_numVerts; index_LUT_t *p_index_LUT, *p_index_LUT2, *p_index_LUT3; index_DUP_LUT_t *p_index_LUT_DUPS; md2Triangle_t *p_md2Triangle; @@ -491,7 +490,6 @@ static picoModel_t *_md2_load( PM_PARAMS_LOAD ) } // Fill in Look Up Table, and allocate/fill Linked List from vert array as needed for dup STs per Vert. - tot_numVerts = md2->numXYZ; dups = 0; for(i=0; inumTris; i++) { diff --git a/tools/quake3/common/imagelib.c b/tools/quake3/common/imagelib.c index 31e3185..b95fe97 100644 --- a/tools/quake3/common/imagelib.c +++ b/tools/quake3/common/imagelib.c @@ -678,7 +678,6 @@ void LoadBMP (const char *filename, byte **pic, byte **palette, int *width, int { byte *out; int i; - int bfSize; int bfOffBits; int structSize; int bcWidth; @@ -701,7 +700,7 @@ void LoadBMP (const char *filename, byte **pic, byte **palette, int *width, int Error ("%s is not a bmp file", filename); } - bfSize = bufLittleLong (in, len, &pos); + /* bfSize = */ bufLittleLong (in, len, &pos); bufLittleShort(in, len, &pos); bufLittleShort(in, len, &pos); bfOffBits = bufLittleLong (in, len, &pos); diff --git a/tools/quake3/common/scriplib.c b/tools/quake3/common/scriplib.c index 47196e5..5502d35 100644 --- a/tools/quake3/common/scriplib.c +++ b/tools/quake3/common/scriplib.c @@ -296,12 +296,11 @@ Returns qtrue if there is another token on the line ============== */ qboolean TokenAvailable (void) { - int oldLine, oldScriptLine; + int oldLine; qboolean r; /* save */ oldLine = scriptline; - oldScriptLine = script->line; /* test */ r = GetToken( qtrue ); -- 2.39.2