summaryrefslogtreecommitdiff
path: root/src/openglgraphics.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2011-09-14 01:46:13 +0300
committerAndrei Karas <akaras@inbox.ru>2011-09-14 01:52:42 +0300
commitc0a5fffb45f849e224750f27fa8c3be5ac447ad6 (patch)
tree1fcac5e9836e119970acae9c5702ac83f40a935f /src/openglgraphics.cpp
parent1c62988a9e7ed1038250a2d044889eda046500c5 (diff)
downloadmanaplus-c0a5fffb45f849e224750f27fa8c3be5ac447ad6.tar.gz
manaplus-c0a5fffb45f849e224750f27fa8c3be5ac447ad6.tar.bz2
manaplus-c0a5fffb45f849e224750f27fa8c3be5ac447ad6.tar.xz
manaplus-c0a5fffb45f849e224750f27fa8c3be5ac447ad6.zip
Add more checks.
Fix error in event.cpp from last commits. Improve party members sorting.
Diffstat (limited to 'src/openglgraphics.cpp')
-rw-r--r--src/openglgraphics.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/openglgraphics.cpp b/src/openglgraphics.cpp
index 332f79823..03d38e7e2 100644
--- a/src/openglgraphics.cpp
+++ b/src/openglgraphics.cpp
@@ -1023,6 +1023,9 @@ SDL_Surface* OpenGLGraphics::getScreenshot()
w, h, 24,
0xff0000, 0x00ff00, 0x0000ff, 0x000000);
+ if (!screenshot)
+ return 0;
+
if (SDL_MUSTLOCK(screenshot))
SDL_LockSurface(screenshot);