|
From: John S. <jst...@us...> - 2009-12-23 06:33:46
|
Module: performous
Branch: master
Commit: bd1eca7ada0c822866da874e8142e2ccaed68518
Author: John Stumpo <st...@js...>
Date: Wed Dec 23 00:17:57 2009 -0500
Remove calls to IMG_Init and IMG_Quit, which are unnecessary when SDL_image is linked directly to the libraries it uses.
(Also, older versions of SDL_image lack them, including the version in Ubuntu.)
---
game/surface.cc | 2 --
1 files changed, 0 insertions(+), 2 deletions(-)
diff --git a/game/surface.cc b/game/surface.cc
index 476c273..a72f769 100644
--- a/game/surface.cc
+++ b/game/surface.cc
@@ -91,9 +91,7 @@ template <typename T> void loader(T& target, std::string filename, bool autocrop
rsvg_term();
} else {
#ifdef LESS_MAGIC
- IMG_Init(0);
SDL_Surface* imgsurf = IMG_Load(filename.c_str());
- IMG_Quit();
if (imgsurf == NULL) {
throw std::runtime_error("Unable to load " + filename + ": " + IMG_GetError());
}
|