]> de.git.xonotic.org Git - xonotic/netradiant.git/commitdiff
fix warning: unused variable 'foo'
authorBen Noordhuis <info@bnoordhuis.nl>
Sat, 17 Mar 2012 22:09:08 +0000 (23:09 +0100)
committerBen Noordhuis <info@bnoordhuis.nl>
Sun, 18 Mar 2012 01:17:09 +0000 (02:17 +0100)
libs/splines/splines.cpp
libs/splines/util_str.cpp
plugins/imagehl/lbmlib.cpp
plugins/surface_heretic2/surfacedialog.cpp
plugins/surface_ufoai/surfacedialog.cpp
tools/quake3/q3map2/light_ydnar.c

index c0d95c01a129e2505ce0a248232674b490655095..b9b7c0c90e4907514e497ed252f2356a8bcdc3f4 100644 (file)
@@ -393,7 +393,6 @@ void idSplineList::setSelectedPoint( idVec3 *p ) {
 
 const idVec3 *idSplineList::getPosition( long t ) {
        static idVec3 interpolatedPos;
-       static long lastTime = -1;
 
        int count = splineTime.Num();
        if ( count == 0 ) {
@@ -644,7 +643,6 @@ bool idCameraDef::waitEvent( int index ) {
 
 void idCameraDef::buildCamera() {
        int i;
-       int lastSwitch = 0;
        idList<float> waits;
        idList<int> targets;
 
@@ -653,7 +651,6 @@ void idCameraDef::buildCamera() {
        // we have a base time layout for the path and the target path
        // now we need to layer on any wait or speed changes
        for ( i = 0; i < events.Num(); i++ ) {
-               idCameraEvent *ev = events[i];
                events[i]->setTriggered( false );
                switch ( events[i]->getType() ) {
                case idCameraEvent::EVENT_TARGET: {
@@ -864,7 +861,8 @@ void idCameraDef::parse( const char *( *text )  ) {
 bool idCameraDef::load( const char *filename ) {
        char *buf;
        const char *buf_p;
-       int length = FS_ReadFile( filename, (void **)&buf );
+
+       FS_ReadFile( filename, (void **)&buf );
        if ( !buf ) {
                return false;
        }
@@ -1363,7 +1361,6 @@ void idSplinePosition::write( fileHandle_t file, const char *p ) {
 }
 
 void idCameraDef::addTarget( const char *name, idCameraPosition::positionType type ) {
-       const char *text = ( name == NULL ) ? va( "target0%d", numTargets() + 1 ) : name;
        idCameraPosition *pos = newFromType( type );
        if ( pos ) {
                pos->setName( name );
index eb51533c93cfbfa57954b726e7caab6efbddde2c..52a01a365fa592f875416a47b09657c54e285852 100644 (file)
@@ -487,9 +487,6 @@ void TestStringClass
        i = a.length();                 // i == 0
        i = c.length();                 // i == 4
 
-       const char *s1 = a.c_str(); // s1 == "\0"
-       const char *s2 = c.c_str(); // s2 == "test\0"
-
        t = new idStr();                        // t->len == 0, t->data == "\0"
        delete t;                           // t == ?
 
index 9262cda2bf91913e30394284deb39a9835306c46..beb83b6db43bdeecd3c229fb2551b01603ac2ded 100644 (file)
@@ -133,8 +133,6 @@ static void LoadIDSP( const char *name, byte ** pic, int *width, int *height ){
        dspriteframetype_t  *pframetype;
        int version;
        int numframes;
-       int size;
-       spriteframetype_t frametype;
        dspriteframe_t *spriteframe;
 
        *pic = NULL;
@@ -201,7 +199,7 @@ static void LoadIDSP( const char *name, byte ** pic, int *width, int *height ){
        *pic = bmpRGBA;
 
 #ifdef DEBUG
-       frametype = spriteframetype_t( LittleLong( pframetype->type ) );
+       spriteframetype_t frametype = spriteframetype_t( LittleLong( pframetype->type ) );
        if ( frametype == SPR_SINGLE ) {
                Sys_Printf( "Single Frame\n" );
        }
index 829ad8d99e0644f5c199bcaf813900f8ee1a784a..fd06da6dc522ea72f7cfbe7cb35ce5f68e0350b2 100644 (file)
@@ -219,7 +219,6 @@ static void on_cancel_button_clicked( GtkButton *button, gpointer user_data );
 void IsFaceConflicting(){
        texdef_t* tmp_texdef;
        texdef_to_face_t* temp_texdef_face_list;
-       char buf[12];
        char texture_name[128];
 
        if ( texdef_face_list_empty() ) {
@@ -328,7 +327,6 @@ static void PopulateTextureComboList(){
        texdef_to_face_t* temp_texdef_face_list;
        char blank[1];
        GList *items = NULL;
-       GList *tmp_item;
        int num_of_list_items = 0;
 
        blank[0] = 0;
@@ -390,7 +388,6 @@ static void GetTexdefInfo_from_Radiant(){
        g_texdef_face_vector.resize( count );
 
        if ( !texdef_face_list_empty() ) {
-               texdef_to_face_t* p = get_texdef_face_list();
                GetSelFacesTexdef( get_texdef_face_list() );
        }
 
@@ -1861,7 +1858,6 @@ static void on_fit_button_clicked( GtkButton *button, gpointer user_data ){
 // Axial Button
 static void on_axial_button_clicked( GtkButton *button, gpointer user_data ){
        texdef_t* tmp_texdef;
-       texdef_t* tmp_orig_texdef;
        texdef_to_face_t* temp_texdef_face_list;
 
        if ( !texdef_face_list_empty() && g_bListenChanged ) {
index c6b9f0c82090983e13788409aa68ecd5f6b1a27e..5e0eebc28baca3066875de4197e4fdcb0b39054e 100644 (file)
@@ -220,7 +220,6 @@ static void on_cancel_button_clicked( GtkButton *button, gpointer user_data );
 void IsFaceConflicting(){
        texdef_t* tmp_texdef;
        texdef_to_face_t* temp_texdef_face_list;
-       char buf[12];
        char texture_name[128];
 
        if ( texdef_face_list_empty() ) {
@@ -329,7 +328,6 @@ static void PopulateTextureComboList(){
        texdef_to_face_t* temp_texdef_face_list;
        char blank[1];
        GList *items = NULL;
-       GList *tmp_item;
        int num_of_list_items = 0;
 
        blank[0] = 0;
@@ -391,7 +389,6 @@ static void GetTexdefInfo_from_Radiant(){
        g_texdef_face_vector.resize( count );
 
        if ( !texdef_face_list_empty() ) {
-               texdef_to_face_t* p = get_texdef_face_list();
                GetSelFacesTexdef( get_texdef_face_list() );
        }
 
@@ -1861,7 +1858,6 @@ static void on_fit_button_clicked( GtkButton *button, gpointer user_data ){
 // Axial Button
 static void on_axial_button_clicked( GtkButton *button, gpointer user_data ){
        texdef_t* tmp_texdef;
-       texdef_t* tmp_orig_texdef;
        texdef_to_face_t* temp_texdef_face_list;
 
        if ( !texdef_face_list_empty() && g_bListenChanged ) {
index 794f2cb8e06390725f41b3e44f17ad07f9d21887..cb0430ea3a0f77ee30ac105415b2826dc6c75de3 100644 (file)
@@ -3179,7 +3179,7 @@ void SetupEnvelopes( qboolean forGrid, qboolean fastFlag ){
        int i, x, y, z, x1, y1, z1;
        light_t     *light, *light2, **owner;
        bspLeaf_t   *leaf;
-       vec3_t origin, dir, mins, maxs, nullVector = { 0, 0, 0 };
+       vec3_t origin, dir, mins, maxs;
        float radius, intensity;
        light_t     *buckets[ 256 ];