Bug 95697 - Assertion editeng/source/items/frmitems.cxx:478: unknown MemberId
Summary: Assertion editeng/source/items/frmitems.cxx:478: unknown MemberId
Status: RESOLVED WORKSFORME
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: framework (show other bugs)
Version:
(earliest affected)
4.4.1.2 release
Hardware: Other All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Crash-Assert
  Show dependency treegraph
 
Reported: 2015-11-09 11:32 UTC by Oliver Specht (CIB)
Modified: 2020-12-29 10:33 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:
Regression By:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Oliver Specht (CIB) 2015-11-09 11:32:27 UTC
SvxLRSpaceItem::QueryValue() at frmitems.cxx:478 0x7f4f6aba4945	
SfxDispatchController_Impl::StateChanged() at unoctitm.cxx:1,011 0x7f4f6982bea0	
SfxStateCache::SetState_Impl() at statcach.cxx:433 0x7f4f69803183	
SfxStateCache::SetState() at statcach.cxx:339 0x7f4f69802cc9	
SfxBindings::UpdateControllers_Impl() at bindings.cxx:1,486 0x7f4f697cf6bf	

Happens because the default value 0 is not supported 
see SvxULSpaceItem::QueryValue() as reference
Comment 1 Buovjaga 2015-11-12 10:10:19 UTC
I believe you, so I set to NEW.
Comment 2 QA Administrators 2017-01-03 19:34:58 UTC Comment hidden (obsolete)
Comment 3 Xisco Faulí 2017-07-25 20:43:57 UTC
Hi Oliver,
Do you know if this assert is still reproducible?
Comment 4 QA Administrators 2018-07-26 02:41:55 UTC Comment hidden (obsolete)
Comment 5 Julien Nabet 2020-07-01 14:19:22 UTC
Is it still reproduceable with last LO version?
If yes, how to do this?
Comment 6 QA Administrators 2020-12-29 03:44:05 UTC Comment hidden (obsolete)
Comment 7 Julien Nabet 2020-12-29 09:54:09 UTC
No feedback after at least 3 years, let's put this one to WFM then.

Oliver: don't hesitate to reopen this tracker if you still reproduce this and by providing a minimum step by step process to reproduce this.
Comment 8 Buovjaga 2020-12-29 10:31:39 UTC Comment hidden (obsolete)
Comment 9 Buovjaga 2020-12-29 10:33:57 UTC
Whoops, my previous comment was for the function that was supposed to be used as reference for a fix. Here is the one Oliver meant:

git blame -L 321,378 editeng/source/items/frmitems.cxx

e65c0fe553a9d editeng/source/items/frmitems.cxx (Thorsten Behrens     2011-03-12 02:42:58 +0100 321) bool SvxLRSpaceItem::QueryValue( uno::Any& rVal, sal_uInt8 nMemberId ) const
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 322) {
45169c93d57ac editeng/source/items/frmitems.cxx (Norbert Thiebaud     2010-10-04 15:23:49 +0100 323)     bool bRet = true;
3edb4611b2314 editeng/source/items/frmitems.cxx (Noel Grandin         2014-04-09 11:03:42 +0200 324)     bool bConvert = 0!=(nMemberId&CONVERT_TWIPS);
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 325)     nMemberId &= ~CONVERT_TWIPS;
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 326)     switch( nMemberId )
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 327)     {
65d891652fd5d editeng/source/items/frmitems.cxx (Albert Thuswaldner   2011-02-16 16:34:02 -0500 328)         // now all signed
723467bd88a50 editeng/source/items/frmitems.cxx (Szymon Kłos          2016-05-31 16:57:13 +0200 329)         case 0:
723467bd88a50 editeng/source/items/frmitems.cxx (Szymon Kłos          2016-05-31 16:57:13 +0200 330)         {
723467bd88a50 editeng/source/items/frmitems.cxx (Szymon Kłos          2016-05-31 16:57:13 +0200 331)             css::frame::status::LeftRightMarginScale aLRSpace;
54a8e708b4822 editeng/source/items/frmitems.cxx (Stephan Bergmann     2018-01-12 20:25:09 +0100 332)             aLRSpace.Left = static_cast<sal_Int32>(bConvert ? convertTwipToMm100(nLeftMargin) : nLeftMargin);
54a8e708b4822 editeng/source/items/frmitems.cxx (Stephan Bergmann     2018-01-12 20:25:09 +0100 333)             aLRSpace.TextLeft = static_cast<sal_Int32>(bConvert ? convertTwipToMm100(nTxtLeft) : nTxtLeft);
54a8e708b4822 editeng/source/items/frmitems.cxx (Stephan Bergmann     2018-01-12 20:25:09 +0100 334)             aLRSpace.Right = static_cast<sal_Int32>(bConvert ? convertTwipToMm100(nRightMargin) : nRightMargin);
54a8e708b4822 editeng/source/items/frmitems.cxx (Stephan Bergmann     2018-01-12 20:25:09 +0100 335)             aLRSpace.ScaleLeft = static_cast<sal_Int16>(nPropLeftMargin);
54a8e708b4822 editeng/source/items/frmitems.cxx (Stephan Bergmann     2018-01-12 20:25:09 +0100 336)             aLRSpace.ScaleRight = static_cast<sal_Int16>(nPropRightMargin);
3eba9b6819941 editeng/source/items/frmitems.cxx (Noel Grandin         2020-02-05 15:22:43 +0200 337)             aLRSpace.FirstLine = static_cast<sal_Int32>(bConvert ? convertTwipToMm100(nFirstLineOffset) : nFirstLineOffset);
fa2389e3f5cbb editeng/source/items/frmitems.cxx (Noel Grandin         2020-02-05 15:21:41 +0200 338)             aLRSpace.ScaleFirstLine = static_cast<sal_Int16>(nPropFirstLineOffset);
723467bd88a50 editeng/source/items/frmitems.cxx (Szymon Kłos          2016-05-31 16:57:13 +0200 339)             aLRSpace.AutoFirstLine = IsAutoFirst();
723467bd88a50 editeng/source/items/frmitems.cxx (Szymon Kłos          2016-05-31 16:57:13 +0200 340)             rVal <<= aLRSpace;
723467bd88a50 editeng/source/items/frmitems.cxx (Szymon Kłos          2016-05-31 16:57:13 +0200 341)             break;
723467bd88a50 editeng/source/items/frmitems.cxx (Szymon Kłos          2016-05-31 16:57:13 +0200 342)         }
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 343)         case MID_L_MARGIN:
54a8e708b4822 editeng/source/items/frmitems.cxx (Stephan Bergmann     2018-01-12 20:25:09 +0100 344)             rVal <<= static_cast<sal_Int32>(bConvert ? convertTwipToMm100(nLeftMargin) : nLeftMargin);
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 345)             break;
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 346) 
1bbb78e822803 svx/source/items/frmitems.cxx     (Oliver Specht        2000-11-01 15:09:10 +0000 347)         case MID_TXT_LMARGIN :
54a8e708b4822 editeng/source/items/frmitems.cxx (Stephan Bergmann     2018-01-12 20:25:09 +0100 348)             rVal <<= static_cast<sal_Int32>(bConvert ? convertTwipToMm100(nTxtLeft) : nTxtLeft);
1bbb78e822803 svx/source/items/frmitems.cxx     (Oliver Specht        2000-11-01 15:09:10 +0000 349)         break;
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 350)         case MID_R_MARGIN:
54a8e708b4822 editeng/source/items/frmitems.cxx (Stephan Bergmann     2018-01-12 20:25:09 +0100 351)             rVal <<= static_cast<sal_Int32>(bConvert ? convertTwipToMm100(nRightMargin) : nRightMargin);
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 352)             break;
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 353)         case MID_L_REL_MARGIN:
54a8e708b4822 editeng/source/items/frmitems.cxx (Stephan Bergmann     2018-01-12 20:25:09 +0100 354)             rVal <<= static_cast<sal_Int16>(nPropLeftMargin);
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 355)         break;
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 356)         case MID_R_REL_MARGIN:
54a8e708b4822 editeng/source/items/frmitems.cxx (Stephan Bergmann     2018-01-12 20:25:09 +0100 357)             rVal <<= static_cast<sal_Int16>(nPropRightMargin);
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 358)         break;
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 359) 
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 360)         case MID_FIRST_LINE_INDENT:
3eba9b6819941 editeng/source/items/frmitems.cxx (Noel Grandin         2020-02-05 15:22:43 +0200 361)             rVal <<= static_cast<sal_Int32>(bConvert ? convertTwipToMm100(nFirstLineOffset) : nFirstLineOffset);
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 362)             break;
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 363) 
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 364)         case MID_FIRST_LINE_REL_INDENT:
fa2389e3f5cbb editeng/source/items/frmitems.cxx (Noel Grandin         2020-02-05 15:21:41 +0200 365)             rVal <<= static_cast<sal_Int16>(nPropFirstLineOffset);
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 366)             break;
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 367) 
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 368)         case MID_FIRST_AUTO:
572e9cde744e2 editeng/source/items/frmitems.cxx (Noel Grandin         2017-04-05 12:26:29 +0200 369)             rVal <<= IsAutoFirst();
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 370)             break;
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 371) 
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 372)         default:
45169c93d57ac editeng/source/items/frmitems.cxx (Norbert Thiebaud     2010-10-04 15:23:49 +0100 373)             bRet = false;
3585cfe5f55f3 editeng/source/items/frmitems.cxx (Michael Stahl        2016-04-22 18:12:03 +0200 374)             // SfxDispatchController_Impl::StateChanged calls this with hardcoded 0 triggering this; there used to be a MID_LR_MARGIN 0 but what type would it have?
65c053ca1a5a8 editeng/source/items/frmitems.cxx (Thomas Arnhold       2011-03-01 19:07:44 +0100 375)             OSL_FAIL("unknown MemberId");
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 376)     }
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 377)     return bRet;
fd069bee7e57a svx/source/items/frmitems.cxx     (Jens-Heiner Rechtien 2000-09-18 16:07:07 +0000 378) }