diff -r 2f3cc8e045d5 -r 69b8adc9a669 src/glCompiler.cc --- a/src/glCompiler.cc Sun Sep 07 01:13:20 2014 +0300 +++ b/src/glCompiler.cc Sun Sep 07 04:11:55 2014 +0300 @@ -280,12 +280,18 @@ QVector vbodata; - for (auto it = m_objectInfo.begin(); it != m_objectInfo.end(); ++it) + for (auto it = m_objectInfo.begin(); it != m_objectInfo.end();) { if (it.key() == null) + { it = m_objectInfo.erase (it); - elif (it.key().toStrongRef()->document() == CurrentDocument() and not it.key().toStrongRef()->isHidden()) + } + elif (it.key().toStrongRef()->document() == CurrentDocument() + and not it.key().toStrongRef()->isHidden()) + { vbodata += it->data[vbonum]; + ++it; + } } glBindBuffer (GL_ARRAY_BUFFER, m_vbo[vbonum]);