diff --git a/binaryurp/source/unmarshal.cxx b/binaryurp/source/unmarshal.cxx index d307c81cc0b5..4263edf8c91c 100644 --- a/binaryurp/source/unmarshal.cxx +++ b/binaryurp/source/unmarshal.cxx @@ -437,6 +437,7 @@ BinaryAny Unmarshal::readSequence(css::uno::TypeDescription const & type) { return BinaryAny(type, &p); } std::vector< BinaryAny > as; + as.reserve(n); for (sal_uInt32 i = 0; i != n; ++i) { as.push_back(readValue(ctd)); } @@ -477,6 +478,7 @@ void Unmarshal::readMemberValues( css::uno::TypeDescription(&ctd->pBaseTypeDescription->aBase), values); } + values->reserve(values->size() + ctd->nMembers); for (sal_Int32 i = 0; i != ctd->nMembers; ++i) { values->push_back( readValue(css::uno::TypeDescription(ctd->ppTypeRefs[i])));