1. mst
  2. ooo340

Commits

Bjoern Michaelsen  committed 5d3400d

CWS new_itemsets: added assertion testing which ID of item

  • Participants
  • Parent commits addf7ed
  • Branches default

Comments (0)

Files changed (1)

File svl/inc/svl/itemset.hxx

View file
  • Ignore whitespace
 
             void SetItem(SfxPoolItem* pItem, SfxItemPool* const io_pPool)
             {
+                OSL_ENSURE(IsInvalidItem(pItem) || pItem->ISA(SfxVoidItem) || pItem->Which() == m_nWhich,
+                    "<ItemEntry::SetItem(..)> - Which Id mismatch.");
                 if(IsInvalidItem(pItem) || IsStaticDefaultItem(pItem))
                     m_pItem = pItem;
                 else if(!pItem->Which())