New Defects reported by Coverity Scan for LibreOffice
scan-admin at coverity.com
scan-admin at coverity.com
Fri Sep 21 04:02:25 UTC 2018
Hi,
Please find the latest report on new defect(s) introduced to LibreOffice found with Coverity Scan.
4 new defect(s) introduced to LibreOffice found with Coverity Scan.
12 defect(s), reported by Coverity Scan earlier, were marked fixed in the recent build analyzed by Coverity Scan.
New defect(s) Reported-by: Coverity Scan
Showing 4 of 4 defect(s)
** CID 1439599: Uninitialized members (UNINIT_CTOR)
/svx/source/dialog/measctrl.cxx: 35 in SvxXMeasurePreview::SvxXMeasurePreview()()
________________________________________________________________________________________________________
*** CID 1439599: Uninitialized members (UNINIT_CTOR)
/svx/source/dialog/measctrl.cxx: 35 in SvxXMeasurePreview::SvxXMeasurePreview()()
29 SvxXMeasurePreview::SvxXMeasurePreview()
30 : m_aMapMode(MapUnit::Map100thMM)
31 {
32 // Scale: 1:2
33 m_aMapMode.SetScaleX(Fraction(1, 2));
34 m_aMapMode.SetScaleY(Fraction(1, 2));
>>> CID 1439599: Uninitialized members (UNINIT_CTOR)
>>> Non-static class member "pMeasureObj" is not initialized in this constructor nor in any functions that it calls.
35 }
36
37 void SvxXMeasurePreview::SetDrawingArea(weld::DrawingArea* pDrawingArea)
38 {
39 CustomWidgetController::SetDrawingArea(pDrawingArea);
40 Size aSize(getPreviewStripSize(pDrawingArea->get_ref_device()));
** CID 1439598: Incorrect expression (MIXED_ENUMS)
/sw/source/uibase/config/modcfg.cxx: 252 in SwRevisionConfig::SwRevisionConfig()()
________________________________________________________________________________________________________
*** CID 1439598: Incorrect expression (MIXED_ENUMS)
/sw/source/uibase/config/modcfg.cxx: 252 in SwRevisionConfig::SwRevisionConfig()()
246 ConfigItemMode::DelayedUpdate|ConfigItemMode::ReleaseTree)
247 {
248 m_aInsertAttr.m_nItemId = SID_ATTR_CHAR_UNDERLINE;
249 m_aInsertAttr.m_nAttr = LINESTYLE_SINGLE;
250 m_aInsertAttr.m_nColor = COL_TRANSPARENT;
251 m_aDeletedAttr.m_nItemId = SID_ATTR_CHAR_STRIKEOUT;
>>> CID 1439598: Incorrect expression (MIXED_ENUMS)
>>> Mixing enum types "FontLineStyle" and "FontStrikeout" for "m_nAttr".
252 m_aDeletedAttr.m_nAttr = STRIKEOUT_SINGLE;
253 m_aDeletedAttr.m_nColor = COL_TRANSPARENT;
254 m_aFormatAttr.m_nItemId = SID_ATTR_CHAR_WEIGHT;
255 m_aFormatAttr.m_nAttr = WEIGHT_BOLD;
256 m_aFormatAttr.m_nColor = COL_BLACK;
257 Load();
** CID 1439597: Null pointer dereferences (REVERSE_INULL)
/sw/source/filter/ww8/ww8atr.cxx: 5520 in AttributeOutputBase::GetParagraphMarkerRedline(const SwTextNode &, unsigned short)()
________________________________________________________________________________________________________
*** CID 1439597: Null pointer dereferences (REVERSE_INULL)
/sw/source/filter/ww8/ww8atr.cxx: 5520 in AttributeOutputBase::GetParagraphMarkerRedline(const SwTextNode &, unsigned short)()
5514 sal_uLong uEndNodeIndex = pCheckedEnd->nNode.GetIndex();
5515 sal_uLong uEndCharIndex = pCheckedEnd->nContent.GetIndex();
5516 sal_uLong uNodeIndex = rNode.GetIndex();
5517
5518 if( uStartNodeIndex <= uNodeIndex && uNodeIndex < uEndNodeIndex )
5519 {
>>> CID 1439597: Null pointer dereferences (REVERSE_INULL)
>>> Null-checking "pCheckedEnd" suggests that it may be null, but it has already been dereferenced on all paths leading to the check.
5520 if ( !pCheckedEnd )
5521 continue;
5522
5523 // Maybe add here a check that also the start & end of the redline is the entire paragraph
5524 if ( ( uStartNodeIndex < uEndNodeIndex ) &&
5525 // check start:
** CID 1439596: Incorrect expression (MIXED_ENUMS)
/sw/source/uibase/config/modcfg.cxx: 255 in SwRevisionConfig::SwRevisionConfig()()
________________________________________________________________________________________________________
*** CID 1439596: Incorrect expression (MIXED_ENUMS)
/sw/source/uibase/config/modcfg.cxx: 255 in SwRevisionConfig::SwRevisionConfig()()
249 m_aInsertAttr.m_nAttr = LINESTYLE_SINGLE;
250 m_aInsertAttr.m_nColor = COL_TRANSPARENT;
251 m_aDeletedAttr.m_nItemId = SID_ATTR_CHAR_STRIKEOUT;
252 m_aDeletedAttr.m_nAttr = STRIKEOUT_SINGLE;
253 m_aDeletedAttr.m_nColor = COL_TRANSPARENT;
254 m_aFormatAttr.m_nItemId = SID_ATTR_CHAR_WEIGHT;
>>> CID 1439596: Incorrect expression (MIXED_ENUMS)
>>> Mixing enum types "FontLineStyle" and "FontWeight" for "m_nAttr".
255 m_aFormatAttr.m_nAttr = WEIGHT_BOLD;
256 m_aFormatAttr.m_nColor = COL_BLACK;
257 Load();
258 }
259
260 SwRevisionConfig::~SwRevisionConfig()
________________________________________________________________________________________________________
To view the defects in Coverity Scan visit, https://u2389337.ct.sendgrid.net/wf/click?upn=08onrYu34A-2BWcWUl-2F-2BfV0V05UPxvVjWch-2Bd2MGckcRZBnDJeNb0HijxaS4JNJPxk3kpyAm2AYqo71yXmnOxB72ibeUH-2F-2F1Lhi9AZq3dRu-2F4-3D_g-2BrHdvqzaBa155F-2F8AmPhpJzY63UzWDisJV95WUBpGhqFw1ICExHG8aMaV2EoFpyWJBDGdq7iEzK5-2BCFtKaqU2JHAavdj7J2sCybtAU44yqSr8fDnJLePHsj-2FcZxvESQsQD3mrf9MW5cQUidl17f4nrGgLQTJkmvkiyTf-2FimV34LCSzMim8xmng9sR4-2Fhoo3rxllW0c4pUUS2qqcvfjzocgotXzZOkTfZGnODX9gvuU-3D
More information about the LibreOffice
mailing list