From 8829d46bda4f09e365cd97b842abdfe4ef571286 Mon Sep 17 00:00:00 2001 From: Lukasz Gromanowski Date: Sun, 12 Feb 2012 15:45:08 +0100 Subject: [PATCH] Clean up compilation warnings. Clan up compilation warnings like "variable ... set but not used" introduced in some older and recent commits. Signed-off-by: Lukasz Gromanowski --- apps/esmtool/esmtool_cmd.c | 18 +++++++++--------- apps/openmw/mwgui/journalwindow.cpp | 4 ++-- apps/openmw/mwrender/animation.cpp | 2 +- apps/openmw/mwrender/npcanimation.cpp | 2 +- components/nif/data.hpp | 4 ++-- components/nifogre/ogre_nif_loader.cpp | 4 ++-- 6 files changed, 17 insertions(+), 17 deletions(-) diff --git a/apps/esmtool/esmtool_cmd.c b/apps/esmtool/esmtool_cmd.c index d6556d9e7..3fce77de2 100644 --- a/apps/esmtool/esmtool_cmd.c +++ b/apps/esmtool/esmtool_cmd.c @@ -926,13 +926,13 @@ int update_arg(void *field, char **orig_field, const char *long_opt, char short_opt, const char *additional_error) { - char *stop_char = 0; - const char *val = value; - int found; + //char *stop_char = 0; + //const char *val = value; + //int found; FIX_UNUSED (field); - stop_char = 0; - found = 0; + //stop_char = 0; + //found = 0; if (!multiple_option && prev_given && (*prev_given || (check_ambiguity && *field_given))) { @@ -955,8 +955,8 @@ int update_arg(void *field, char **orig_field, (*prev_given)++; if (field_given) (*field_given)++; - if (possible_values) - val = possible_values[found]; + //if (possible_values) + //val = possible_values[found]; switch(arg_type) { default: @@ -996,7 +996,7 @@ cmdline_parser_internal ( int override; int initialize; - int check_required; + //int check_required; int check_ambiguity; char *optarg; @@ -1008,7 +1008,7 @@ cmdline_parser_internal ( override = params->override; initialize = params->initialize; - check_required = params->check_required; + //check_required = params->check_required; check_ambiguity = params->check_ambiguity; if (initialize) diff --git a/apps/openmw/mwgui/journalwindow.cpp b/apps/openmw/mwgui/journalwindow.cpp index 457a07582..3f3c89f39 100644 --- a/apps/openmw/mwgui/journalwindow.cpp +++ b/apps/openmw/mwgui/journalwindow.cpp @@ -32,8 +32,8 @@ book formatText(std::string text,book mBook,int maxLine, int lineSize) mBook.pages.pop_back(); } - std::string::iterator wordBegin = text.begin(); - std::string::iterator wordEnd; + //std::string::iterator wordBegin = text.begin(); + //std::string::iterator wordEnd; std::string cText = text; diff --git a/apps/openmw/mwrender/animation.cpp b/apps/openmw/mwrender/animation.cpp index 5a9731d2d..056550e74 100644 --- a/apps/openmw/mwrender/animation.cpp +++ b/apps/openmw/mwrender/animation.cpp @@ -499,7 +499,7 @@ namespace MWRender{ std::vector quats = iter->getQuat(); std::vector ttime = iter->gettTime(); - std::vector::iterator ttimeiter = ttime.begin(); + //std::vector::iterator ttimeiter = ttime.begin(); std::vector rtime = iter->getrTime(); int rindexJ = 0; diff --git a/apps/openmw/mwrender/npcanimation.cpp b/apps/openmw/mwrender/npcanimation.cpp index 863f7577b..fe48aa321 100644 --- a/apps/openmw/mwrender/npcanimation.cpp +++ b/apps/openmw/mwrender/npcanimation.cpp @@ -267,7 +267,7 @@ void NpcAnimation::runAnimation(float timepassed){ } handleAnimationTransforms(); - Ogre::Vector3 current = insert->_getWorldAABB().getCenter(); + //Ogre::Vector3 current = insert->_getWorldAABB().getCenter(); std::vector*>::iterator shapepartsiter = shapeparts.begin(); std::vector::iterator entitypartsiter = entityparts.begin(); diff --git a/components/nif/data.hpp b/components/nif/data.hpp index 9e28e1534..df9079758 100644 --- a/components/nif/data.hpp +++ b/components/nif/data.hpp @@ -473,7 +473,7 @@ void read(NIFFile *nif) int vertCount = nif->getInt(); nif->getByte(); int magic = nif->getInt(); - int type = nif->getInt(); + /*int type =*/ nif->getInt(); for(int i = 0; i < vertCount; i++){ float x = nif->getFloat(); @@ -485,7 +485,7 @@ void read(NIFFile *nif) for(int i=1; igetInt(); - type = nif->getInt(); + /*type =*/ nif->getInt(); std::vector current; std::vector currentTime; for(int i = 0; i < magic; i++){ diff --git a/components/nifogre/ogre_nif_loader.cpp b/components/nifogre/ogre_nif_loader.cpp index c62f59ea3..2662f0c97 100644 --- a/components/nifogre/ogre_nif_loader.cpp +++ b/components/nifogre/ogre_nif_loader.cpp @@ -1150,7 +1150,7 @@ void NIFLoader::loadResource(Resource *resource) char suffix = name.at(name.length() - 2); bool addAnim = true; bool hasAnim = false; - bool baddin = false; + //bool baddin = false; bNiTri = true; if(suffix == '*') @@ -1168,7 +1168,7 @@ void NIFLoader::loadResource(Resource *resource) } else if(suffix == '>') { - baddin = true; + //baddin = true; bNiTri = true; std::string sub = name.substr(name.length() - 6, 4);