Hi, Please find the latest report on new defect(s) introduced to LibreOffice found with Coverity Scan.
50 new defect(s) introduced to LibreOffice found with Coverity Scan. 5 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 20 of 50 defect(s) ** CID 1430104: API usage errors (SWAPPED_ARGUMENTS) ________________________________________________________________________________________________________ *** CID 1430104: API usage errors (SWAPPED_ARGUMENTS) /editeng/source/editeng/impedit.cxx: 621 in ImpEditView::GetWindowPos(const tools::Rectangle &) const() 615 { 616 aRect = tools::Rectangle( aPos, aSz ); 617 } 618 else 619 { 620 Point aNewPos( aPos.X()-aSz.Height(), aPos.Y() ); >>> CID 1430104: API usage errors (SWAPPED_ARGUMENTS) >>> The positions of arguments in the constructor for "Size" do not match >>> the ordering of the parameters: * "aSz.Height()" is passed to "nWidth" * "aSz.Width()" is passed to "nHeight" 621 aRect = tools::Rectangle( aNewPos, Size( aSz.Height(), aSz.Width() ) ); 622 } 623 return aRect; 624 } 625 626 void ImpEditView::SetSelectionMode( EESelectionMode eNewMode ) ** CID 1430103: Integer handling issues (DIVIDE_BY_ZERO) /sc/source/ui/StatisticsDialogs/SamplingDialog.cxx: 204 in ScSamplingDialog::PerformPeriodicSampling(ScDocShell *)() ________________________________________________________________________________________________________ *** CID 1430103: Integer handling issues (DIVIDE_BY_ZERO) /sc/source/ui/StatisticsDialogs/SamplingDialog.cxx: 204 in ScSamplingDialog::PerformPeriodicSampling(ScDocShell *)() 198 for (SCCOL inCol = aStart.Col(); inCol <= aEnd.Col(); inCol++) 199 { 200 sal_Int64 i = 0; 201 outRow = mOutputAddress.Row(); 202 for (SCROW inRow = aStart.Row(); inRow <= aEnd.Row(); inRow++) 203 { >>> CID 1430103: Integer handling issues (DIVIDE_BY_ZERO) >>> In expression "i % aPeriod", modulo by expression "aPeriod" which may >>> be zero has undefined behavior. 204 if (i % aPeriod == aPeriod - 1 ) // Sample the last of period 205 { 206 double aValue = mDocument->GetValue(ScAddress(inCol, inRow, inTab)); 207 pDocShell->GetDocFunc().SetValueCell(ScAddress(outCol, outRow, outTab), aValue, true); 208 outRow++; 209 } ** CID 1430102: (DIVIDE_BY_ZERO) /sw/source/ui/misc/pggrid.cxx: 389 in SwTextGridPage::CharorLineChangedHdl(SpinField &)() /sw/source/ui/misc/pggrid.cxx: 410 in SwTextGridPage::CharorLineChangedHdl(SpinField &)() /sw/source/ui/misc/pggrid.cxx: 420 in SwTextGridPage::CharorLineChangedHdl(SpinField &)() ________________________________________________________________________________________________________ *** CID 1430102: (DIVIDE_BY_ZERO) /sw/source/ui/misc/pggrid.cxx: 389 in SwTextGridPage::CharorLineChangedHdl(SpinField &)() 383 { 384 //if in squared mode 385 if ( m_bSquaredMode ) 386 { 387 if(m_pCharsPerLineNF == &rField) 388 { >>> CID 1430102: (DIVIDE_BY_ZERO) >>> In expression "this->m_aPageSize.Width() / >>> this->m_pCharsPerLineNF->GetValue()", division by expression >>> "this->m_pCharsPerLineNF->GetValue()" which may be zero has undefined >>> behavior. 389 long nWidth = static_cast<long>(m_aPageSize.Width() / m_pCharsPerLineNF->GetValue()); 390 m_pTextSizeMF->SetValue(m_pTextSizeMF->Normalize(nWidth), FUNIT_TWIP); 391 //prevent rounding errors in the MetricField by saving the used value 392 m_nRubyUserValue = nWidth; 393 m_bRubyUserValue = true; 394 /sw/source/ui/misc/pggrid.cxx: 410 in SwTextGridPage::CharorLineChangedHdl(SpinField &)() 404 SetLinesOrCharsRanges( *m_pCharsRangeFT , m_pCharsPerLineNF->GetMax() ); 405 } 406 else//in normal mode 407 { 408 if(m_pLinesPerPageNF == &rField) 409 { >>> CID 1430102: (DIVIDE_BY_ZERO) >>> In expression "this->m_aPageSize.Height() / >>> this->m_pLinesPerPageNF->GetValue()", division by expression >>> "this->m_pLinesPerPageNF->GetValue()" which may be zero has undefined >>> behavior. 410 long nHeight = static_cast< sal_Int32 >(m_aPageSize.Height() / m_pLinesPerPageNF->GetValue()); 411 m_pTextSizeMF->SetValue(m_pTextSizeMF->Normalize(nHeight), FUNIT_TWIP); 412 m_pRubySizeMF->SetValue(0, FUNIT_TWIP); 413 SetLinesOrCharsRanges( *m_pLinesRangeFT , m_pLinesPerPageNF->GetMax() ); 414 415 m_nRubyUserValue = nHeight; /sw/source/ui/misc/pggrid.cxx: 420 in SwTextGridPage::CharorLineChangedHdl(SpinField &)() 414 415 m_nRubyUserValue = nHeight; 416 m_bRubyUserValue = true; 417 } 418 else if (m_pCharsPerLineNF == &rField) 419 { >>> CID 1430102: (DIVIDE_BY_ZERO) >>> In expression "this->m_aPageSize.Width() / >>> this->m_pCharsPerLineNF->GetValue()", division by expression >>> "this->m_pCharsPerLineNF->GetValue()" which may be zero has undefined >>> behavior. 420 long nWidth = static_cast< sal_Int32 >(m_aPageSize.Width() / m_pCharsPerLineNF->GetValue()); 421 m_pCharWidthMF->SetValue(m_pCharWidthMF->Normalize(nWidth), FUNIT_TWIP); 422 SetLinesOrCharsRanges( *m_pCharsRangeFT , m_pCharsPerLineNF->GetMax() ); 423 } 424 } 425 GridModifyHdl(); ** CID 1430101: Incorrect expression (DIVIDE_BY_ZERO) /sc/source/ui/view/drawvie4.cxx: 562 in ScDrawView::FitToCellSize()() ________________________________________________________________________________________________________ *** CID 1430101: Incorrect expression (DIVIDE_BY_ZERO) /sc/source/ui/view/drawvie4.cxx: 562 in ScDrawView::FitToCellSize()() 556 tools::Rectangle aCellRect = ScDrawLayer::GetCellRect( *pDoc, pObjData->maStart, true); 557 558 // For graphic objects, we want to keep the aspect ratio 559 if (pObj->shouldKeepAspectRatio()) 560 { 561 double fScaleX = static_cast<double>(aCellRect.GetWidth()) / static_cast<double>(aGraphicRect.GetWidth()); >>> CID 1430101: Incorrect expression (DIVIDE_BY_ZERO) >>> In expression "static_cast<double>(aCellRect.GetHeight()) / >>> static_cast<double>(aGraphicRect.GetHeight())", division by expression >>> "aGraphicRect.GetHeight()" which may be zero has undefined behavior. 562 double fScaleY = static_cast<double>(aCellRect.GetHeight()) / static_cast<double>(aGraphicRect.GetHeight()); 563 double fScaleMin = std::min(fScaleX, fScaleY); 564 565 aCellRect.setWidth(static_cast<double>(aGraphicRect.GetWidth()) * fScaleMin); 566 aCellRect.setHeight(static_cast<double>(aGraphicRect.GetHeight()) * fScaleMin); 567 } ** CID 1430100: Uninitialized members (UNINIT_CTOR) /sw/source/core/attr/calbck.cxx: 39 in SwClient::SwClient(SwClient&&)() ________________________________________________________________________________________________________ *** CID 1430100: Uninitialized members (UNINIT_CTOR) /sw/source/core/attr/calbck.cxx: 39 in SwClient::SwClient(SwClient&&)() 33 { 34 if(o.m_pRegisteredIn) 35 { 36 o.m_pRegisteredIn->Add(this); 37 o.EndListeningAll(); 38 } >>> CID 1430100: Uninitialized members (UNINIT_CTOR) >>> Non-static class member "m_pRegisteredIn" is not initialized in this >>> constructor nor in any functions that it calls. 39 } 40 41 42 SwClient::~SwClient() 43 { 44 if(GetRegisteredIn()) ** CID 1430099: Integer handling issues (DIVIDE_BY_ZERO) /sd/source/ui/dlg/vectdlg.cxx: 176 in SdVectorizeDlg::Calculate(const Bitmap &, GDIMetaFile &)() ________________________________________________________________________________________________________ *** CID 1430099: Integer handling issues (DIVIDE_BY_ZERO) /sd/source/ui/dlg/vectdlg.cxx: 176 in SdVectorizeDlg::Calculate(const Bitmap &, GDIMetaFile &)() 170 { 171 const long nWidth = pRAcc->Width(); 172 const long nHeight = pRAcc->Height(); 173 const long nTileX = static_cast<long>(m_pMtFillHoles->GetValue()); 174 const long nTileY = static_cast<long>(m_pMtFillHoles->GetValue()); 175 const long nCountX = nWidth / nTileX; >>> CID 1430099: Integer handling issues (DIVIDE_BY_ZERO) >>> In expression "nHeight / nTileY", division by expression "nTileY" which >>> may be zero has undefined behavior. 176 const long nCountY = nHeight / nTileY; 177 const long nRestX = nWidth % nTileX; 178 const long nRestY = nHeight % nTileY; 179 180 MapMode aMap( rMtf.GetPrefMapMode() ); 181 aNewMtf.SetPrefSize( rMtf.GetPrefSize() ); ** CID 1430098: Uninitialized members (UNINIT_CTOR) /vcl/source/window/dialog.cxx: 573 in Dialog::Dialog(vcl::Window *, const rtl::OUString &, const rtl::OUString &, WindowType, Dialog::InitFlag, bool)() ________________________________________________________________________________________________________ *** CID 1430098: Uninitialized members (UNINIT_CTOR) /vcl/source/window/dialog.cxx: 573 in Dialog::Dialog(vcl::Window *, const rtl::OUString &, const rtl::OUString &, WindowType, Dialog::InitFlag, bool)() 567 , mbForceBorderWindow(bBorder) 568 , mnInitFlag(eFlag) 569 { 570 ImplLOKNotifier(pParent); 571 ImplInitDialogData(); 572 loadUI(pParent, OUStringToOString(rID, RTL_TEXTENCODING_UTF8), rUIXMLDescription); >>> CID 1430098: Uninitialized members (UNINIT_CTOR) >>> Non-static class member "mbInSyncExecute" is not initialized in this >>> constructor nor in any functions that it calls. 573 } 574 575 Dialog::Dialog(vcl::Window* pParent, WinBits nStyle, InitFlag eFlag) 576 : SystemWindow(WindowType::DIALOG) 577 , mbForceBorderWindow(false) 578 , mnInitFlag(eFlag) ** CID 1430097: Null pointer dereferences (NULL_RETURNS) ________________________________________________________________________________________________________ *** CID 1430097: Null pointer dereferences (NULL_RETURNS) /sc/source/ui/view/drawvie4.cxx: 556 in ScDrawView::FitToCellSize()() 550 return; 551 } 552 553 SdrUndoGroup* pUndoGroup = new SdrUndoGroup(*GetModel()); 554 ScDrawObjData* pObjData = ScDrawLayer::GetObjData(pObj); 555 tools::Rectangle aGraphicRect = pObj->GetSnapRect(); >>> CID 1430097: Null pointer dereferences (NULL_RETURNS) >>> Dereferencing a pointer that might be null "pObjData->maStart" when >>> calling "GetCellRect". 556 tools::Rectangle aCellRect = ScDrawLayer::GetCellRect( *pDoc, pObjData->maStart, true); 557 558 // For graphic objects, we want to keep the aspect ratio 559 if (pObj->shouldKeepAspectRatio()) 560 { 561 double fScaleX = static_cast<double>(aCellRect.GetWidth()) / static_cast<double>(aGraphicRect.GetWidth()); ** CID 1430096: (UNINIT_CTOR) /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<writerfilter::dmapper::PropertyIds>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<writerfilter::dmapper::FieldId>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<_XDisplay *>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<char16_t>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<com::sun::star::drawing::FillStyle>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<unsigned short>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<long>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<FontItalic>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<FontRelief>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<FontWeight>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<FontLineStyle>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<FontStrikeout>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<FontEmphasisMark>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<const SvxFontItem *>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<com::sun::star::style::ParagraphAdjust>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<_GdkAtom *>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<short>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<dbaccess::ODatabaseModelImpl::EmbeddedMacros>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<unsigned char>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<signed char>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<bool>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<unsigned int>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<char>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<int>::tc_optional_base()() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<double>::tc_optional_base()() ________________________________________________________________________________________________________ *** CID 1430096: (UNINIT_CTOR) /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<writerfilter::dmapper::PropertyIds>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<writerfilter::dmapper::FieldId>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<_XDisplay *>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<char16_t>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<com::sun::star::drawing::FillStyle>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<unsigned short>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<long>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<FontItalic>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<FontRelief>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<FontWeight>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<FontLineStyle>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<FontStrikeout>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<FontEmphasisMark>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<const SvxFontItem *>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<com::sun::star::style::ParagraphAdjust>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<_GdkAtom *>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<short>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<dbaccess::ODatabaseModelImpl::EmbeddedMacros>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<unsigned char>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<signed char>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<bool>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<unsigned int>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<char>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<int>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 27 in boost::optional_detail::tc_optional_base<double>::tc_optional_base()() 21 typedef T * pointer_type ; 22 typedef T const* pointer_const_type ; 23 typedef T const& argument_type ; 24 25 tc_optional_base() 26 : >>> CID 1430096: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : 31 m_initialized(false) {} 32 ** CID 1430095: Error handling issues (UNCAUGHT_EXCEPT) /sfx2/source/dialog/alienwarn.cxx: 71 in SfxAlienWarningDialog::~SfxAlienWarningDialog()() ________________________________________________________________________________________________________ *** CID 1430095: Error handling issues (UNCAUGHT_EXCEPT) /sfx2/source/dialog/alienwarn.cxx: 71 in SfxAlienWarningDialog::~SfxAlienWarningDialog()() 65 m_xUseDefaultFormatBtn->set_label(sInfoText); 66 67 // load value of "warning on" checkbox from save options 68 m_xWarningOnBox->set_active(SvtSaveOptions().IsWarnAlienFormat()); 69 } 70 >>> CID 1430095: Error handling issues (UNCAUGHT_EXCEPT) >>> An exception of type "com::sun::star::uno::RuntimeException" is thrown >>> but the throw list "throw()" doesn't allow it to be thrown. This will cause >>> a call to unexpected() which usually calls terminate(). 71 SfxAlienWarningDialog::~SfxAlienWarningDialog() 72 { 73 m_xContentArea->remove(m_xWarningOnBox.get()); 74 m_xOrigParent->add(m_xWarningOnBox.get()); 75 // save value of "warning off" checkbox, if necessary 76 SvtSaveOptions aSaveOpt; ** CID 1430094: API usage errors (SWAPPED_ARGUMENTS) ________________________________________________________________________________________________________ *** CID 1430094: API usage errors (SWAPPED_ARGUMENTS) /svx/source/svdraw/svdpage.cxx: 1336 in SdrPage::SetOrientation(Orientation)() 1330 void SdrPage::SetOrientation(Orientation eOri) 1331 { 1332 // square: handle like portrait format 1333 Size aSiz(GetSize()); 1334 if (aSiz.Width()!=aSiz.Height()) { 1335 if ((eOri==Orientation::Portrait) == (aSiz.Width()>aSiz.Height())) { >>> CID 1430094: API usage errors (SWAPPED_ARGUMENTS) >>> The positions of arguments in the constructor for "Size" do not match >>> the ordering of the parameters: * "aSiz.Height()" is passed to "nWidth" * "aSiz.Width()" is passed to "nHeight" 1336 SetSize(Size(aSiz.Height(),aSiz.Width())); 1337 } 1338 } 1339 } 1340 1341 Orientation SdrPage::GetOrientation() const ** CID 1430093: Control flow issues (DEADCODE) /editeng/source/uno/unotext2.cxx: 67 in SvxUnoTextContentEnumeration::SvxUnoTextContentEnumeration(const SvxUnoTextBase &, const ESelection &)() ________________________________________________________________________________________________________ *** CID 1430093: Control flow issues (DEADCODE) /editeng/source/uno/unotext2.cxx: 67 in SvxUnoTextContentEnumeration::SvxUnoTextContentEnumeration(const SvxUnoTextBase &, const ESelection &)() 61 nEndPos = std::min(nEndPos, maSelection.nEndPos); 62 ESelection aCurrentParaSel = ESelection( currentPara, nStartPos, currentPara, nEndPos ); 63 for (auto const& elemRange : rRanges) 64 { 65 if (!pContent) 66 break; >>> CID 1430093: Control flow issues (DEADCODE) >>> Execution cannot reach this statement: "pIterContent = dynamic_cast...". 67 SvxUnoTextContent* pIterContent = dynamic_cast< SvxUnoTextContent* >( elemRange ); 68 if( pIterContent && (pIterContent->mnParagraph == currentPara) ) 69 { 70 ESelection aIterSel = pIterContent->GetSelection(); 71 if( aIterSel == aCurrentParaSel ) 72 { ** CID 1430092: Incorrect expression (NO_EFFECT) /usr/include/boost/array.hpp: 118 in boost::array<long, (unsigned long)2>::operator [](unsigned long)() ________________________________________________________________________________________________________ *** CID 1430092: Incorrect expression (NO_EFFECT) /usr/include/boost/array.hpp: 118 in boost::array<long, (unsigned long)2>::operator [](unsigned long)() 112 return const_reverse_iterator(begin()); 113 } 114 115 // operator[] 116 reference operator[](size_type i) 117 { >>> CID 1430092: Incorrect expression (NO_EFFECT) >>> Comparing an array to null is not useful: ""out of range"", since the >>> test will always evaluate as true. 118 return BOOST_ASSERT_MSG( i < N, "out of range" ), elems[i]; 119 } 120 121 /*BOOST_CONSTEXPR*/ const_reference operator[](size_type i) const 122 { 123 return BOOST_ASSERT_MSG( i < N, "out of range" ), elems[i]; ** CID 1430091: Error handling issues (CHECKED_RETURN) /svx/qa/unit/XTableImportExportTest.cxx: 71 in XTableImportExportTest::testImportExport()() ________________________________________________________________________________________________________ *** CID 1430091: Error handling issues (CHECKED_RETURN) /svx/qa/unit/XTableImportExportTest.cxx: 71 in XTableImportExportTest::testImportExport()() 65 66 aChecksum = aBitmap.GetChecksum(); 67 } 68 69 { 70 XBitmapList xBitmapList(aTempURL, "REF"); >>> CID 1430091: Error handling issues (CHECKED_RETURN) >>> Calling "Load" without checking return value (as is done elsewhere 7 >>> out of 8 times). 71 xBitmapList.Load(); 72 uno::Reference<container::XNameContainer> xNameContainer(xBitmapList.createInstance()); 73 CPPUNIT_ASSERT(xNameContainer.is()); 74 75 uno::Any aAny = xNameContainer->getByName("SomeBitmap"); 76 CPPUNIT_ASSERT(aAny.has<uno::Reference<awt::XBitmap>>()); ** CID 1430090: Uninitialized members (UNINIT_CTOR) /sfx2/source/appl/openuriexternally.cxx: 38 in URITools::URITools()() ________________________________________________________________________________________________________ *** CID 1430090: Uninitialized members (UNINIT_CTOR) /sfx2/source/appl/openuriexternally.cxx: 38 in URITools::URITools()() 32 33 class URITools 34 { 35 private: 36 Timer aOpenURITimer; 37 OUString msURI; >>> CID 1430090: Uninitialized members (UNINIT_CTOR) >>> The compiler-generated constructor for this class does not initialize >>> "mbHandleSystemShellExecuteException". 38 bool mbHandleSystemShellExecuteException; 39 DECL_LINK(onOpenURI, Timer*, void); 40 41 public: 42 void openURI(const OUString& sURI, bool bHandleSystemShellExecuteException); 43 }; ** CID 1430089: Incorrect expression (COPY_PASTE_ERROR) /vcl/source/outdev/text.cxx: 334 in OutputDevice::ImplDrawSpecialText(SalLayout &)() ________________________________________________________________________________________________________ *** CID 1430089: Incorrect expression (COPY_PASTE_ERROR) /vcl/source/outdev/text.cxx: 334 in OutputDevice::ImplDrawSpecialText(SalLayout &)() 328 aTextLineColor = COL_WHITE; 329 if ( aOverlineColor == COL_BLACK ) 330 aOverlineColor = COL_WHITE; 331 332 // relief-color is black for white text, in all other cases 333 // we set this to LightGray >>> CID 1430089: Incorrect expression (COPY_PASTE_ERROR) >>> "aTextColor" looks like a copy-paste error. 334 if ( aTextColor == COL_WHITE ) 335 aReliefColor = COL_BLACK; 336 SetTextLineColor( aReliefColor ); 337 SetOverlineColor( aReliefColor ); 338 SetTextColor( aReliefColor ); 339 ImplInitTextColor(); ** CID 1430088: (UNINIT_CTOR) /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 31 in boost::optional_detail::tc_optional_base<unsigned short>::tc_optional_base(boost::none_t)() /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 31 in boost::optional_detail::tc_optional_base<short>::tc_optional_base(boost::none_t)() ________________________________________________________________________________________________________ *** CID 1430088: (UNINIT_CTOR) /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 31 in boost::optional_detail::tc_optional_base<unsigned short>::tc_optional_base(boost::none_t)() 25 tc_optional_base() 26 : 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : >>> CID 1430088: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 31 m_initialized(false) {} 32 33 tc_optional_base ( argument_type val ) 34 : 35 m_initialized(true), m_storage(val) {} 36 /usr/include/boost/optional/detail/optional_trivially_copyable_base.hpp: 31 in boost::optional_detail::tc_optional_base<short>::tc_optional_base(boost::none_t)() 25 tc_optional_base() 26 : 27 m_initialized(false) {} 28 29 tc_optional_base ( none_t ) 30 : >>> CID 1430088: (UNINIT_CTOR) >>> Non-static class member "m_storage" is not initialized in this >>> constructor nor in any functions that it calls. 31 m_initialized(false) {} 32 33 tc_optional_base ( argument_type val ) 34 : 35 m_initialized(true), m_storage(val) {} 36 ** CID 1430087: (DIVIDE_BY_ZERO) /cui/source/tabpages/grfpage.cxx: 497 in SvxGrfCropPage::CropHdl(SpinField &)() /cui/source/tabpages/grfpage.cxx: 503 in SvxGrfCropPage::CropHdl(SpinField &)() ________________________________________________________________________________________________________ *** CID 1430087: (DIVIDE_BY_ZERO) /cui/source/tabpages/grfpage.cxx: 497 in SvxGrfCropPage::CropHdl(SpinField &)() 491 long nWidthZoom = static_cast<long>(m_pWidthZoomMF->GetValue()); 492 if(bZoom && ( ( ( aOrigSize.Width() - (nLeft + nRight )) * nWidthZoom ) 493 / 100 >= aPageSize.Width() ) ) 494 { 495 if(&rField == m_pLeftMF) 496 { >>> CID 1430087: (DIVIDE_BY_ZERO) >>> In expression "this->aPageSize.Width() * 100L / nWidthZoom", division >>> by expression "nWidthZoom" which may be zero has undefined behavior. 497 nLeft = aOrigSize.Width() - 498 ( aPageSize.Width() * 100 / nWidthZoom + nRight ); 499 m_pLeftMF->SetValue( m_pLeftMF->Normalize( nLeft ), eUnit ); 500 } 501 else 502 { /cui/source/tabpages/grfpage.cxx: 503 in SvxGrfCropPage::CropHdl(SpinField &)() 497 nLeft = aOrigSize.Width() - 498 ( aPageSize.Width() * 100 / nWidthZoom + nRight ); 499 m_pLeftMF->SetValue( m_pLeftMF->Normalize( nLeft ), eUnit ); 500 } 501 else 502 { >>> CID 1430087: (DIVIDE_BY_ZERO) >>> In expression "this->aPageSize.Width() * 100L / nWidthZoom", division >>> by expression "nWidthZoom" which may be zero has undefined behavior. 503 nRight = aOrigSize.Width() - 504 ( aPageSize.Width() * 100 / nWidthZoom + nLeft ); 505 m_pRightMF->SetValue( m_pRightMF->Normalize( nRight ), eUnit ); 506 } 507 } 508 if (AllSettings::GetLayoutRTL()) ** CID 1430086: Incorrect expression (DIVIDE_BY_ZERO) /sc/source/core/data/drwlayer.cxx: 682 in ScDrawLayer::ResizeLastRectFromAnchor(const SdrObject *, ScDrawObjData &, bool, bool, bool, bool)() ________________________________________________________________________________________________________ *** CID 1430086: Incorrect expression (DIVIDE_BY_ZERO) /sc/source/core/data/drwlayer.cxx: 682 in ScDrawLayer::ResizeLastRectFromAnchor(const SdrObject *, ScDrawObjData &, bool, bool, bool, bool)() 676 677 if (pObj->shouldKeepAspectRatio()) 678 { 679 tools::Rectangle aRectIncludingOffset = aRect; 680 aRectIncludingOffset.setWidth(aRect.GetWidth() + rData.maStartOffset.X()); 681 aRectIncludingOffset.setHeight(aRect.GetHeight() + rData.maStartOffset.Y()); >>> CID 1430086: Incorrect expression (DIVIDE_BY_ZERO) >>> In expression "static_cast<double>(aCurrentCellRect.GetWidth()) / >>> static_cast<double>(aRectIncludingOffset.GetWidth())", division by >>> expression "aRectIncludingOffset.GetWidth()" which may be zero has >>> undefined behavior. 682 double fMaxWidthFactor = static_cast<double>(aCurrentCellRect.GetWidth()) 683 / static_cast<double>(aRectIncludingOffset.GetWidth()); 684 double fMaxHeightFactor = static_cast<double>(aCurrentCellRect.GetHeight()) 685 / static_cast<double>(aRectIncludingOffset.GetHeight()); 686 double fMaxFactor = std::min(fMaxHeightFactor, fMaxWidthFactor); 687 ** CID 1430085: Integer handling issues (DIVIDE_BY_ZERO) ________________________________________________________________________________________________________ *** CID 1430085: Integer handling issues (DIVIDE_BY_ZERO) /sw/source/ui/dbui/mmoutputtypepage.cxx: 295 in SwSendMailDialog::SwSendMailDialog(vcl::Window *, SwMailMergeConfigItem &)() 289 m_pStatus->SetStyle( m_pStatus->GetStyle() | WB_SORT | WB_HSCROLL | WB_CLIPCHILDREN | WB_TABSTOP ); 290 m_pStatus->SetSelectionMode( SelectionMode::Single ); 291 m_pStatus->SetTabs(&nTabs[0], MapUnit::MapPixel); 292 m_pStatus->SetSpaceBetweenEntries(3); 293 294 m_pPaused->Show(false); >>> CID 1430085: Integer handling issues (DIVIDE_BY_ZERO) >>> In function call "UpdateTransferStatus", division by expression >>> "this->m_nExpectedCount" which may be zero has undefined behavior. 295 UpdateTransferStatus(); 296 } 297 298 SwSendMailDialog::~SwSendMailDialog() 299 { 300 disposeOnce(); ________________________________________________________________________________________________________ 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-2F8AmPhpJzY63UzWDisJV95WUBpGhqFw1ICExHG8aMaV2EoFpysrWzgEd6kilWR2DLBR-2BVsx-2BOsnzr10fWgVtUdFk-2BdVYPjXjQ1L6ZVRxDCsuE7Ojoxo-2Bl-2B2bE1q8K21wuO0uCFYVEM1soRegXz-2BpnDEtOT3ep9UXXR1tD-2BMWE5ZPNe-2FQVKUaT0EwTRSTU1Dp3mNu870PtRXh1QrtLUaGTwWWFpj8-3D _______________________________________________ LibreOffice mailing list LibreOffice@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice