From c09c1b97843f7e6cc362f2ee25e94259a4961732 Mon Sep 17 00:00:00 2001 From: unknown Date: Fri, 3 Nov 2006 23:56:25 +1100 Subject: BUG#22299 mgmd crash due to unchecked TransporterFacade::ThreadData expand() abort if we ever fail to expand a Vector ndb/include/util/Vector.hpp: abort on failure to allocate memory --- ndb/include/util/Vector.hpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ndb/include/util/Vector.hpp b/ndb/include/util/Vector.hpp index 480dddf8243..e7f83ff9d2c 100644 --- a/ndb/include/util/Vector.hpp +++ b/ndb/include/util/Vector.hpp @@ -94,6 +94,8 @@ void Vector::push_back(const T & t){ if(m_size == m_arraySize){ T * tmp = new T [m_arraySize + m_incSize]; + if(!tmp) + abort(); for (unsigned k = 0; k < m_size; k++) tmp[k] = m_items[k]; delete[] m_items; -- cgit v1.2.1