diff options
Diffstat (limited to 'bridges')
-rw-r--r-- | bridges/source/cpp_uno/shared/vtablefactory.cxx | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/bridges/source/cpp_uno/shared/vtablefactory.cxx b/bridges/source/cpp_uno/shared/vtablefactory.cxx index a40e9e08b53d..9eb4d690204f 100644 --- a/bridges/source/cpp_uno/shared/vtablefactory.cxx +++ b/bridges/source/cpp_uno/shared/vtablefactory.cxx @@ -155,11 +155,12 @@ sal_Int32 VtableFactory::BaseOffset::calculate( typelib_InterfaceTypeDescription * type, sal_Int32 offset) { OUString name(type->aBase.pTypeName); - if (m_map.find(name) == m_map.end()) { + auto it = m_map.find(name); + if (it == m_map.end()) { for (sal_Int32 i = 0; i < type->nBaseTypes; ++i) { offset = calculate(type->ppBaseTypes[i], offset); } - m_map.insert({name, offset}); + m_map.insert(it, {name, offset}); typelib_typedescription_complete( reinterpret_cast< typelib_TypeDescription ** >(&type)); offset += bridges::cpp_uno::shared::getLocalFunctions(type); |