Commits

Anonymous committed 5dde985

tl77: #i115684#: fix performance regression: replace deque with vector

Comments (0)

Files changed (2)

svl/source/inc/poolio.hxx

  *
  ************************************************************************/
 
-#include <deque>
+#include <vector>
 
 #include <svl/brdcst.hxx>
 
 #endif
 
 
-typedef std::deque<SfxPoolItem*> SfxPoolItemArrayBase_Impl;
+typedef std::vector<SfxPoolItem*> SfxPoolItemArrayBase_Impl;
 
 struct SfxPoolItemArray_Impl: public SfxPoolItemArrayBase_Impl
 {

svl/source/items/itempool.cxx

 	if( !*ppItemArr )
 		*ppItemArr = new SfxPoolItemArray_Impl;
 
-	SfxPoolItemArrayBase_Impl::iterator ppFree;
+    SfxPoolItemArrayBase_Impl::iterator ppFree = (*ppItemArr)->end();
 	BOOL ppFreeIsSet = FALSE;
 	SfxPoolItemArrayBase_Impl::iterator ppHtArray = (*ppItemArr)->begin();
 	if ( IsItemFlag_Impl( nIndex, SFX_ITEM_POOLABLE ) )