From 5bb7857bb2d50c4e1cc0ca10e66ff32236acf900 Mon Sep 17 00:00:00 2001 From: Georg Baum Date: Sun, 15 Mar 2015 13:56:48 +0100 Subject: [PATCH] Add missing check The other insert method has this as well, and it is indeed a problem is pos points outside the vector. --- src/mathed/MathData.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/mathed/MathData.cpp b/src/mathed/MathData.cpp index edd8089457..fe73aa8965 100644 --- a/src/mathed/MathData.cpp +++ b/src/mathed/MathData.cpp @@ -68,6 +68,7 @@ MathAtom const & MathData::operator[](pos_type pos) const void MathData::insert(size_type pos, MathAtom const & t) { + LBUFERR(pos <= size()); base_type::insert(begin() + pos, t); } -- 2.39.5