summaryrefslogtreecommitdiff
path: root/src/resources
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2012-09-05 15:55:55 +0300
committerAndrei Karas <akaras@inbox.ru>2012-09-05 15:55:55 +0300
commitd1bb1b375d657f0821ccfebf18fa1c3873314690 (patch)
treeeb83bbf7242b2c367c4df19113f37f6c6ab9faa2 /src/resources
parent9f87b4c92e3a4d524250dbbb376cd0f59b7d995e (diff)
downloadmanaverse-d1bb1b375d657f0821ccfebf18fa1c3873314690.tar.gz
manaverse-d1bb1b375d657f0821ccfebf18fa1c3873314690.tar.bz2
manaverse-d1bb1b375d657f0821ccfebf18fa1c3873314690.tar.xz
manaverse-d1bb1b375d657f0821ccfebf18fa1c3873314690.zip
Fix useless variables initialisations.
Diffstat (limited to 'src/resources')
-rw-r--r--src/resources/resourcemanager.cpp1
-rw-r--r--src/resources/sdlimagehelper.cpp3
2 files changed, 1 insertions, 3 deletions
diff --git a/src/resources/resourcemanager.cpp b/src/resources/resourcemanager.cpp
index c06f9c181..2e6a381fa 100644
--- a/src/resources/resourcemanager.cpp
+++ b/src/resources/resourcemanager.cpp
@@ -193,7 +193,6 @@ bool ResourceManager::cleanOrphans(const bool always)
return false;
bool status(false);
- status = false;
ResourceIterator iter = mOrphanedResources.begin();
while (iter != mOrphanedResources.end())
{
diff --git a/src/resources/sdlimagehelper.cpp b/src/resources/sdlimagehelper.cpp
index 9a1822e32..5c02d0e2e 100644
--- a/src/resources/sdlimagehelper.cpp
+++ b/src/resources/sdlimagehelper.cpp
@@ -48,7 +48,6 @@ Resource *SDLImageHelper::load(SDL_RWops *const rw, Dye const &dye)
return nullptr;
}
- SDL_Surface *surf = nullptr;
SDL_PixelFormat rgba;
rgba.palette = nullptr;
rgba.BitsPerPixel = 32;
@@ -60,7 +59,7 @@ Resource *SDLImageHelper::load(SDL_RWops *const rw, Dye const &dye)
rgba.Bmask = 0x0000FF00; rgba.Bloss = 0; rgba.Bshift = 8;
rgba.Amask = 0x000000FF; rgba.Aloss = 0; rgba.Ashift = 0;
- surf = SDL_ConvertSurface(tmpImage, &rgba, SDL_SWSURFACE);
+ SDL_Surface *surf = SDL_ConvertSurface(tmpImage, &rgba, SDL_SWSURFACE);
SDL_FreeSurface(tmpImage);
uint32_t *pixels = static_cast<uint32_t *>(surf->pixels);