Kaydet (Commit) 733e6028 authored tarafından Caolán McNamara's avatar Caolán McNamara Kaydeden (comit) Andras Timar

ofz#6173 check index before use

Change-Id: I09d15ab324af0a8b3566f11868eb3266a68c4afe
Reviewed-on: https://gerrit.libreoffice.org/49500Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarMichael Stahl <mstahl@redhat.com>
(cherry picked from commit e355d7d6)
üst 4debe26a
......@@ -167,7 +167,9 @@ bool SwCTBWrapper::Read( SvStream& rS )
std::vector< sal_Int16 >::iterator it_end = dropDownMenuIndices.end();
for ( std::vector< sal_Int16 >::iterator it = dropDownMenuIndices.begin(); it != it_end; ++it )
{
rCustomizations[ *it ].bIsDroppedMenuTB = true;
if (*it < 0 || static_cast<size_t>(*it) >= rCustomizations.size())
continue;
rCustomizations[*it].bIsDroppedMenuTB = true;
}
return rS.good();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment