summaryrefslogtreecommitdiff
path: root/src/render/modernopenglgraphics.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2018-03-27 00:42:00 +0300
committerAndrei Karas <akaras@inbox.ru>2018-03-27 00:42:00 +0300
commit9452e1a39fe74b56b8667b088b9674358dcb52a2 (patch)
tree524b8467772c72c439e8340063193154bcd04948 /src/render/modernopenglgraphics.cpp
parent22e1d3794fb293a5336d66199fb7463aeea7faf9 (diff)
downloadmanaplus-9452e1a39fe74b56b8667b088b9674358dcb52a2.tar.gz
manaplus-9452e1a39fe74b56b8667b088b9674358dcb52a2.tar.bz2
manaplus-9452e1a39fe74b56b8667b088b9674358dcb52a2.tar.xz
manaplus-9452e1a39fe74b56b8667b088b9674358dcb52a2.zip
Fix empty vector issue in modern and mobile2 opengl renderers.
Diffstat (limited to 'src/render/modernopenglgraphics.cpp')
-rw-r--r--src/render/modernopenglgraphics.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/render/modernopenglgraphics.cpp b/src/render/modernopenglgraphics.cpp
index c792021ef..473b8d264 100644
--- a/src/render/modernopenglgraphics.cpp
+++ b/src/render/modernopenglgraphics.cpp
@@ -1304,6 +1304,8 @@ void ModernOpenGLGraphics::finalize(ImageVertexes *restrict const vert)
STD_VECTOR<GLuint>::const_iterator ivbo;
const int sz = CAST_S32(intTexPool.size());
+ if (sz == 0)
+ return;
vbos.resize(sz);
mglGenBuffers(sz, &vbos[0]);
/*