Hi,
Please find the latest report on new defect(s) introduced to LibreOffice found
with Coverity Scan.
61 new defect(s) introduced to LibreOffice found with Coverity Scan.
17 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 61 defect(s)
** CID 1667103: Integer handling issues (INTEGER_OVERFLOW)
/cui/source/tabpages/tpline.cxx: 781 in
SvxLineTabPage::FillXLSet_Impl()()
_____________________________________________________________________________________________
*** CID 1667103: Integer handling issues (INTEGER_OVERFLOW)
/cui/source/tabpages/tpline.cxx: 781 in
SvxLineTabPage::FillXLSet_Impl()()
775 if( m_xTsbCenterEnd->get_state() == TRISTATE_TRUE )
776 m_rXLSet.Put( XLineEndCenterItem( true ) );
777 else if( m_xTsbCenterEnd->get_state() == TRISTATE_FALSE )
778 m_rXLSet.Put( XLineEndCenterItem( false ) );
779
780 // Transparency
>>> CID 1667103: Integer handling issues (INTEGER_OVERFLOW)
>>> Expression "nVal", where
>>> "this->m_xMtrTransparent->get_value(FieldUnit::PERCENT)" is known to be
>>> equal to -9223372036854775808, overflows the type of "nVal", which is type
>>> "sal_uInt16".
781 sal_uInt16 nVal = m_xMtrTransparent->get_value(FieldUnit::PERCENT);
782 m_rXLSet.Put( XLineTransparenceItem( nVal ) );
783
784 m_aCtlPreview.SetLineAttributes(m_aXLineAttr.GetItemSet());
785 }
786
** CID 1667102: Concurrent data access violations (MISSING_LOCK)
/vcl/source/app/session.cxx: 285 in
<unnamed>::VCLSession::removeSessionManagerListener(const
com::sun::star::uno::Reference<com::sun::star::frame::XSessionManagerListener>
&)::[lambda() (instance 2)]::operator ()() const()
_____________________________________________________________________________________________
*** CID 1667102: Concurrent data access violations (MISSING_LOCK)
/vcl/source/app/session.cxx: 285 in
<unnamed>::VCLSession::removeSessionManagerListener(const
com::sun::star::uno::Reference<com::sun::star::frame::XSessionManagerListener>
&)::[lambda() (instance 2)]::operator ()() const()
279 void SAL_CALL VCLSession::removeSessionManagerListener( const
css::uno::Reference<XSessionManagerListener>& xListener )
280 {
281 SAL_INFO("vcl.se", "VCLSession::removeSessionManagerListener" );
282
283 std::unique_lock aGuard( m_aMutex );
284
>>> CID 1667102: Concurrent data access violations (MISSING_LOCK)
>>> Accessing "this->this->m_aListeners" without holding lock
>>> "comphelper::UnoImplBase.m_aMutex". Elsewhere,
>>> "<unnamed>::VCLSession.m_aListeners" is written to with
>>> "UnoImplBase.m_aMutex" held 2 out of 2 times.
285 SAL_INFO("vcl.se.debug", " m_aListeners.size() = " <<
m_aListeners.size() );
286
287 std::erase_if(m_aListeners, [&](Listener& listener) {return
xListener == listener.m_xListener;});
288 }
289
290 void SAL_CALL VCLSession::queryInteraction( const
css::uno::Reference<XSessionManagerListener>& xListener )
** CID 1667101: Integer handling issues (INTEGER_OVERFLOW)
/sw/source/uibase/utlui/prcntfld.cxx: 240 in
SwPercentField::Convert(long, FieldUnit, FieldUnit)()
_____________________________________________________________________________________________
*** CID 1667101: Integer handling issues (INTEGER_OVERFLOW)
/sw/source/uibase/utlui/prcntfld.cxx: 240 in
SwPercentField::Convert(long, FieldUnit, FieldUnit)()
234 if (eInUnit == FieldUnit::TWIP) // Only convert if necessary
235 nCurrentWidth = nValue;
236 else
237 nCurrentWidth = vcl::ConvertValue(nValue, 0, m_nOldDigits,
eInUnit, FieldUnit::TWIP);
238 nCurrentWidth = UpscaleTwoDecimalPlaces(nCurrentWidth,
m_nOldDigits);
239 // Round to 0.5 percent
>>> CID 1667101: Integer handling issues (INTEGER_OVERFLOW)
>>> Expression "nCurrentWidth * 1000L", where "nCurrentWidth" is known to
>>> be equal to -9223372036854775808, overflows the type of "nCurrentWidth *
>>> 1000L", which is type "long".
240 return m_nRefValue ? (((nCurrentWidth * 1000) / m_nRefValue +
5) / 10) : 0;
241 }
242
243 return vcl::ConvertValue(nValue, 0, m_nOldDigits, eInUnit,
eOutUnit);
244 }
** CID 1667100: Integer handling issues (INTEGER_OVERFLOW)
/cui/source/tabpages/tptrans.cxx: 96 in
SvxTransparenceTabPage::ModifyTransparentHdl_Impl(weld::MetricSpinButton &)()
_____________________________________________________________________________________________
*** CID 1667100: Integer handling issues (INTEGER_OVERFLOW)
/cui/source/tabpages/tptrans.cxx: 96 in
SvxTransparenceTabPage::ModifyTransparentHdl_Impl(weld::MetricSpinButton &)()
90 {
91 m_xMtrTransparent->set_sensitive(bActivate);
92 }
93
94 IMPL_LINK_NOARG(SvxTransparenceTabPage, ModifyTransparentHdl_Impl,
weld::MetricSpinButton&, void)
95 {
>>> CID 1667100: Integer handling issues (INTEGER_OVERFLOW)
>>> Expression "nPos", where
>>> "this->m_xMtrTransparent->get_value(FieldUnit::PERCENT)" is known to be
>>> equal to -9223372036854775808, overflows the type of "nPos", which is type
>>> "sal_uInt16".
96 sal_uInt16 nPos = m_xMtrTransparent->get_value(FieldUnit::PERCENT);
97 rXFSet.Put(XFillTransparenceItem(nPos));
98
99 // preview
100 InvalidatePreview();
101 }
** CID 1667099: Integer handling issues (INTEGER_OVERFLOW)
/cui/source/tabpages/tpgradnt.cxx: 313 in
SvxGradientTabPage::ModifiedHdl_Impl(const void *)()
_____________________________________________________________________________________________
*** CID 1667099: Integer handling issues (INTEGER_OVERFLOW)
/cui/source/tabpages/tpgradnt.cxx: 313 in
SvxGradientTabPage::ModifiedHdl_Impl(const void *)()
307 css::awt::GradientStyle eXGS =
static_cast<css::awt::GradientStyle>(m_xLbGradientType->get_active());
308
309 sal_uInt16 nValue = 0; // automatic
310 if (!m_xCbIncrement->get_active())
311 nValue = static_cast<sal_uInt16>(m_xMtrIncrement->get_value());
312
>>> CID 1667099: Integer handling issues (INTEGER_OVERFLOW)
>>> Expression "this->m_xMtrAngle->get_value(FieldUnit::NONE) * 10L", where
>>> "this->m_xMtrAngle->get_value(FieldUnit::NONE)" is known to be equal to
>>> -9223372036854775808, overflows the type of
>>> "this->m_xMtrAngle->get_value(FieldUnit::NONE) * 10L", which is type "long".
313 basegfx::BGradient aBGradient(
314 createColorStops(),
315 eXGS,
316
Degree10(static_cast<sal_Int16>(m_xMtrAngle->get_value(FieldUnit::NONE) * 10)),
// should be changed in resource
317
static_cast<sal_uInt16>(m_xMtrCenterX->get_value(FieldUnit::NONE)),
318
static_cast<sal_uInt16>(m_xMtrCenterY->get_value(FieldUnit::NONE)),
** CID 1667098: (INTEGER_OVERFLOW)
/sd/source/ui/dlg/vectdlg.cxx: 309 in SdVectorizeDlg::SaveSettings()
const()
/sd/source/ui/dlg/vectdlg.cxx: 307 in SdVectorizeDlg::SaveSettings()
const()
_____________________________________________________________________________________________
*** CID 1667098: (INTEGER_OVERFLOW)
/sd/source/ui/dlg/vectdlg.cxx: 309 in
SdVectorizeDlg::SaveSettings() const()
303 {
304 std::shared_ptr<comphelper::ConfigurationChanges> batch(
305 comphelper::ConfigurationChanges::create());
306
officecfg::Office::Common::Vectorize::ColorCount::set(m_xNmLayers->get_value(),batch);
307
officecfg::Office::Common::Vectorize::PointReduce::set(m_xMtReduce->get_value(FieldUnit::NONE),batch);
308
officecfg::Office::Common::Vectorize::FillHole::set(m_xCbFillHoles->get_active(),batch);
>>> CID 1667098: (INTEGER_OVERFLOW)
>>> Expression "<temporary>", where
>>> "this->m_xMtFillHoles->get_value(FieldUnit::NONE)" is known to be equal to
>>> -9223372036854775808, overflows the type of "<temporary>", which is type
>>> "sal_Int16 const".
309
officecfg::Office::Common::Vectorize::TileExtent::set(m_xMtFillHoles->get_value(FieldUnit::NONE),batch);
310 batch->commit();
311 }
312
/sd/source/ui/dlg/vectdlg.cxx: 307 in
SdVectorizeDlg::SaveSettings() const()
301
302 void SdVectorizeDlg::SaveSettings() const
303 {
304 std::shared_ptr<comphelper::ConfigurationChanges> batch(
305 comphelper::ConfigurationChanges::create());
306
officecfg::Office::Common::Vectorize::ColorCount::set(m_xNmLayers->get_value(),batch);
>>> CID 1667098: (INTEGER_OVERFLOW)
>>> Expression "<temporary>", where
>>> "this->m_xMtReduce->get_value(FieldUnit::NONE)" is known to be equal to
>>> -9223372036854775808, overflows the type of "<temporary>", which is type
>>> "sal_Int16 const".
307
officecfg::Office::Common::Vectorize::PointReduce::set(m_xMtReduce->get_value(FieldUnit::NONE),batch);
308
officecfg::Office::Common::Vectorize::FillHole::set(m_xCbFillHoles->get_active(),batch);
309
officecfg::Office::Common::Vectorize::TileExtent::set(m_xMtFillHoles->get_value(FieldUnit::NONE),batch);
310 batch->commit();
311 }
312
** CID 1667097: Integer handling issues (INTEGER_OVERFLOW)
/cui/source/tabpages/paragrph.cxx: 1699 in
SvxParaAlignTabPage::WordSpacingMinimumHdl_Impl(weld::MetricSpinButton &)()
_____________________________________________________________________________________________
*** CID 1667097: Integer handling issues (INTEGER_OVERFLOW)
/cui/source/tabpages/paragrph.cxx: 1699 in
SvxParaAlignTabPage::WordSpacingMinimumHdl_Impl(weld::MetricSpinButton &)()
1693 if (nDesired >
m_xWordSpacingMaximum->get_value(FieldUnit::PERCENT))
1694 m_xWordSpacingMaximum->set_value(nDesired, FieldUnit::PERCENT);
1695 }
1696
1697 IMPL_LINK_NOARG(SvxParaAlignTabPage, WordSpacingMinimumHdl_Impl,
weld::MetricSpinButton&, void)
1698 {
>>> CID 1667097: Integer handling issues (INTEGER_OVERFLOW)
>>> Expression "nMinimum", where
>>> "this->m_xWordSpacingMinimum->get_value(FieldUnit::PERCENT)" is known to be
>>> equal to -9223372036854775808, overflows the type of "nMinimum", which is
>>> type "sal_Int16".
1699 sal_Int16 nMinimum =
m_xWordSpacingMinimum->get_value(FieldUnit::PERCENT);
1700 if (nMinimum > m_xWordSpacing->get_value(FieldUnit::PERCENT))
1701 m_xWordSpacing->set_value(nMinimum, FieldUnit::PERCENT);
1702 if (nMinimum >
m_xWordSpacingMaximum->get_value(FieldUnit::PERCENT))
1703 m_xWordSpacingMaximum->set_value(nMinimum, FieldUnit::PERCENT);
1704 }
** CID 1667096: Insecure data handling (INTEGER_OVERFLOW)
/cui/source/dialogs/zoom.cxx: 40 in SvxZoomDialog::GetFactor() const()
_____________________________________________________________________________________________
*** CID 1667096: Insecure data handling (INTEGER_OVERFLOW)
/cui/source/dialogs/zoom.cxx: 40 in SvxZoomDialog::GetFactor()
const()
34 sal_uInt16 SvxZoomDialog::GetFactor() const
35 {
36 if (m_x100Btn->get_active())
37 return 100;
38
39 if (m_xUserBtn->get_active())
>>> CID 1667096: Insecure data handling (INTEGER_OVERFLOW)
>>> "this->m_xUserEdit->get_value(FieldUnit::PERCENT)" has a value of
>>> -9223372036854775808 which overflows the return type, "sal_uInt16".
40 return
static_cast<sal_uInt16>(m_xUserEdit->get_value(FieldUnit::PERCENT));
41 else
42 return SPECIAL_FACTOR;
43 }
44
45 void SvxZoomDialog::SetFactor(sal_uInt16 nNewFactor, ZoomButtonId
nButtonId)
** CID 1667095: Integer handling issues (INTEGER_OVERFLOW)
/sd/source/ui/animations/CustomAnimationDialog.cxx: 524 in
sd::<unnamed>::SdRotationPropertyBox::updateMenu()()
_____________________________________________________________________________________________
*** CID 1667095: Integer handling issues (INTEGER_OVERFLOW)
/sd/source/ui/animations/CustomAnimationDialog.cxx: 524 in
sd::<unnamed>::SdRotationPropertyBox::updateMenu()()
518 }
519
520 void SdRotationPropertyBox::updateMenu()
521 {
522 sal_Int64 nValue = mxMetric->get_value(FieldUnit::DEGREE);
523 bool bDirection = nValue >= 0;
>>> CID 1667095: Integer handling issues (INTEGER_OVERFLOW)
>>> Expression "-nValue", where "nValue" is known to be equal to
>>> -9223372036854775808, overflows the type of "-nValue", which is type
>>> "sal_Int64".
524 nValue = (nValue < 0 ? -nValue : nValue);
525
526 mxControl->set_item_active(u"90"_ustr, nValue == 90);
527 mxControl->set_item_active(u"180"_ustr, nValue == 180);
528 mxControl->set_item_active(u"360"_ustr, nValue == 360);
529 mxControl->set_item_active(u"720"_ustr, nValue == 720);
** CID 1667094: Integer handling issues (INTEGER_OVERFLOW)
/sw/source/uibase/utlui/prcntfld.cxx: 140 in
SwPercentField::set_value(long, FieldUnit)()
_____________________________________________________________________________________________
*** CID 1667094: Integer handling issues (INTEGER_OVERFLOW)
/sw/source/uibase/utlui/prcntfld.cxx: 140 in
SwPercentField::set_value(long, FieldUnit)()
134 else
135 {
136 sal_Int64 nValue = Convert(nNewValue, eInUnit, m_eOldUnit);
137 nCurrentWidth = vcl::ConvertValue(nValue, 0, m_nOldDigits,
m_eOldUnit, FieldUnit::TWIP);
138 }
139 nCurrentWidth = UpscaleTwoDecimalPlaces(nCurrentWidth,
m_nOldDigits);
>>> CID 1667094: Integer handling issues (INTEGER_OVERFLOW)
>>> Expression "nCurrentWidth * 10L", where "nCurrentWidth" is known to be
>>> equal to -9223372036854775808, overflows the type of "nCurrentWidth * 10L",
>>> which is type "long".
140 nPercent = m_nRefValue ? (((nCurrentWidth * 10) / m_nRefValue +
5) / 10) : 0;
141 m_pField->set_value(nPercent, FieldUnit::NONE);
142 }
143 }
144
145 sal_Int64 SwPercentField::get_value(FieldUnit eOutUnit)
** CID 1667093: Concurrent data access violations (MISSING_LOCK)
/vcl/source/app/session.cxx: 294 in
<unnamed>::VCLSession::queryInteraction(const
com::sun::star::uno::Reference<com::sun::star::frame::XSessionManagerListener>
&)::[lambda() (instance 2)]::operator ()() const()
_____________________________________________________________________________________________
*** CID 1667093: Concurrent data access violations (MISSING_LOCK)
/vcl/source/app/session.cxx: 294 in
<unnamed>::VCLSession::queryInteraction(const
com::sun::star::uno::Reference<com::sun::star::frame::XSessionManagerListener>
&)::[lambda() (instance 2)]::operator ()() const()
288 }
289
290 void SAL_CALL VCLSession::queryInteraction( const
css::uno::Reference<XSessionManagerListener>& xListener )
291 {
292 SAL_INFO("vcl.se", "VCLSession::queryInteraction");
293
>>> CID 1667093: Concurrent data access violations (MISSING_LOCK)
>>> Accessing "this->this->m_bInteractionGranted" without holding lock
>>> "comphelper::UnoImplBase.m_aMutex". Elsewhere,
>>> "<unnamed>::VCLSession.m_bInteractionGranted" is written to with
>>> "UnoImplBase.m_aMutex" held 4 out of 4 times.
294 SAL_INFO("vcl.se.debug", " m_bInteractionGranted = " <<
(m_bInteractionGranted ? "true" : "false") <<
295 ", m_bInteractionRequested = "<<
(m_bInteractionRequested ? "true" : "false"));
296
297 std::unique_lock aGuard( m_aMutex );
298
299 if( m_bInteractionGranted )
** CID 1667092: Concurrent data access violations (MISSING_LOCK)
/drawinglayer/source/processor2d/vclhelperbufferdevice.cxx: 268 in
<unnamed>::VDevBuffer::free(VirtualDevice &)::[lambda() (instance 2)]::operator
()() const()
_____________________________________________________________________________________________
*** CID 1667092: Concurrent data access violations (MISSING_LOCK)
/drawinglayer/source/processor2d/vclhelperbufferdevice.cxx: 268 in
<unnamed>::VDevBuffer::free(VirtualDevice &)::[lambda() (instance 2)]::operator
()() const()
262 SAL_WARN_IF(aUsedFound == maUsedBuffers.end(), "drawinglayer",
263 "OOps, non-registered buffer freed (!)");
264 if (aUsedFound != maUsedBuffers.end())
265 {
266 maFreeBuffers.emplace_back(*aUsedFound);
267 maUsedBuffers.erase(aUsedFound);
>>> CID 1667092: Concurrent data access violations (MISSING_LOCK)
>>> Accessing "this->this->maFreeBuffers" without holding lock
>>> "<unnamed>::VDevBuffer.m_aMutex". Elsewhere,
>>> "<unnamed>::VDevBuffer.maFreeBuffers" is written to with
>>> "VDevBuffer.m_aMutex" held 3 out of 3 times.
268 SAL_WARN_IF(maFreeBuffers.size() > 1000, "drawinglayer",
269 "excessive cached buffers, " <<
maFreeBuffers.size() << " entries!");
270 }
271 Start();
272 }
273
** CID 1667091: Insecure data handling (INTEGER_OVERFLOW)
/dbaccess/source/ui/dlg/dlgsize.cxx: 63 in dbaui::DlgSize::GetValue()
const()
_____________________________________________________________________________________________
*** CID 1667091: Insecure data handling (INTEGER_OVERFLOW)
/dbaccess/source/ui/dlg/dlgsize.cxx: 63 in
dbaui::DlgSize::GetValue() const()
57 }
58
59 sal_Int32 DlgSize::GetValue() const
60 {
61 if (m_xCB_STANDARD->get_active())
62 return -1;
>>> CID 1667091: Insecure data handling (INTEGER_OVERFLOW)
>>> "this->m_xMF_VALUE->get_value(FieldUnit::CM)" has a value of
>>> -9223372036854775808 which overflows the return type, "sal_Int32".
63 return static_cast<sal_Int32>(m_xMF_VALUE->get_value( FieldUnit::CM
));
64 }
65
66 IMPL_LINK_NOARG(DlgSize, CbClickHdl, weld::Toggleable&, void)
67 {
68 m_xMF_VALUE->set_sensitive(!m_xCB_STANDARD->get_active());
** CID 1667090: Integer handling issues (INTEGER_OVERFLOW)
/cui/source/tabpages/tpline.cxx: 1363 in
SvxLineTabPage::ChangeTransparentHdl_Impl(weld::MetricSpinButton &)()
_____________________________________________________________________________________________
*** CID 1667090: Integer handling issues (INTEGER_OVERFLOW)
/cui/source/tabpages/tpline.cxx: 1363 in
SvxLineTabPage::ChangeTransparentHdl_Impl(weld::MetricSpinButton &)()
1357
1358 ChangePreviewHdl_Impl(nullptr);
1359 }
1360
1361 IMPL_LINK_NOARG(SvxLineTabPage, ChangeTransparentHdl_Impl,
weld::MetricSpinButton&, void)
1362 {
>>> CID 1667090: Integer handling issues (INTEGER_OVERFLOW)
>>> Expression "nVal", where
>>> "this->m_xMtrTransparent->get_value(FieldUnit::PERCENT)" is known to be
>>> equal to -9223372036854775808, overflows the type of "nVal", which is type
>>> "sal_uInt16".
1363 sal_uInt16 nVal = m_xMtrTransparent->get_value(FieldUnit::PERCENT);
1364
1365 m_rXLSet.Put(XLineTransparenceItem(nVal));
1366
1367 FillXLSet_Impl();
1368
** CID 1667089: Insecure data handling (INTEGER_OVERFLOW)
/svx/source/tbxctrls/fontworkgallery.cxx: 817 in
svx::FontworkCharacterSpacingDialog::getScale() const()
_____________________________________________________________________________________________
*** CID 1667089: Insecure data handling (INTEGER_OVERFLOW)
/svx/source/tbxctrls/fontworkgallery.cxx: 817 in
svx::FontworkCharacterSpacingDialog::getScale() const()
811 FontworkCharacterSpacingDialog::~FontworkCharacterSpacingDialog()
812 {
813 }
814
815 sal_Int32 FontworkCharacterSpacingDialog::getScale() const
816 {
>>> CID 1667089: Insecure data handling (INTEGER_OVERFLOW)
>>> "this->m_xMtrScale->get_value(FieldUnit::PERCENT)" has a value of
>>> -9223372036854775808 which overflows the return type, "sal_Int32".
817 return
static_cast<sal_Int32>(m_xMtrScale->get_value(FieldUnit::PERCENT));
818 }
819
820 }
821
** CID 1667088: Integer handling issues (INTEGER_OVERFLOW)
/sw/source/ui/frmdlg/wrap.cxx: 579 in
SwWrapTabPage::RangeModifyHdl(weld::MetricSpinButton &)()
_____________________________________________________________________________________________
*** CID 1667088: Integer handling issues (INTEGER_OVERFLOW)
/sw/source/ui/frmdlg/wrap.cxx: 579 in
SwWrapTabPage::RangeModifyHdl(weld::MetricSpinButton &)()
573 assert(pOpposite);
574
575 if (pOpposite)
576 {
577 auto nOpposite = pOpposite->get_value(FieldUnit::NONE);
578
>>> CID 1667088: Integer handling issues (INTEGER_OVERFLOW)
>>> Expression "nValue + nOpposite", where "nValue" is known to be equal to
>>> -9223372036854775808, and "nOpposite" is known to be equal to
>>> -9223372036854775808, overflows the type of "nValue + nOpposite", which is
>>> type "long".
579 if (nValue + nOpposite >
std::max(rEdit.get_max(FieldUnit::NONE), pOpposite->get_max(FieldUnit::NONE)))
580 pOpposite->set_value(pOpposite->get_max(FieldUnit::NONE) -
nValue, FieldUnit::NONE);
581 }
582 }
583
584 IMPL_LINK_NOARG(SwWrapTabPage, WrapTypeHdl, weld::Toggleable&, void)
** CID 1667087: Integer handling issues (INTEGER_OVERFLOW)
/sc/source/ui/sidebar/AlignmentPropertyPanel.cxx: 151 in
sc::sidebar::AlignmentPropertyPanel::AngleModifiedHdl(weld::MetricSpinButton
&)()
_____________________________________________________________________________________________
*** CID 1667087: Integer handling issues (INTEGER_OVERFLOW)
/sc/source/ui/sidebar/AlignmentPropertyPanel.cxx: 151 in
sc::sidebar::AlignmentPropertyPanel::AngleModifiedHdl(weld::MetricSpinButton
&)()
145 GetBindings()->GetDispatcher()->ExecuteList(SID_ATTR_ALIGN_LOCKPOS,
146 SfxCallMode::RECORD, { &aItem });
147 }
148
149 IMPL_LINK_NOARG( AlignmentPropertyPanel, AngleModifiedHdl,
weld::MetricSpinButton&, void )
150 {
>>> CID 1667087: Integer handling issues (INTEGER_OVERFLOW)
>>> Expression "this->mxMtrAngle->get_value(FieldUnit::DEGREE) * 100L",
>>> where "this->mxMtrAngle->get_value(FieldUnit::DEGREE)" is known to be equal
>>> to -9223372036854775808, overflows the type of
>>> "this->mxMtrAngle->get_value(FieldUnit::DEGREE) * 100L", which is type
>>> "long".
151 Degree100 nAngle(mxMtrAngle->get_value(FieldUnit::DEGREE) * 100);
152 ScRotateValueItem aAngleItem(nAngle);
153
154 GetBindings()->GetDispatcher()->ExecuteList(
155 SID_ATTR_ALIGN_DEGREES, SfxCallMode::RECORD, { &aAngleItem });
156 }
** CID 1667086: Integer handling issues (INTEGER_OVERFLOW)
/cui/source/tabpages/textanim.cxx: 363 in
SvxTextAnimationPage::FillItemSet(SfxItemSet *)()
_____________________________________________________________________________________________
*** CID 1667086: Integer handling issues (INTEGER_OVERFLOW)
/cui/source/tabpages/textanim.cxx: 363 in
SvxTextAnimationPage::FillItemSet(SfxItemSet *)()
357 m_xMtrFldAmount->get_value_changed_from_saved())
358 {
359 sal_Int64 nValue = 0;
360 if( eState == TRISTATE_TRUE )
361 {
362 nValue = m_xMtrFldAmount->get_value(FieldUnit::NONE);
>>> CID 1667086: Integer handling issues (INTEGER_OVERFLOW)
>>> Expression "-nValue", where "nValue" is known to be equal to
>>> -9223372036854775808, overflows the type of "-nValue", which is type
>>> "sal_Int64".
363 nValue = -nValue;
364 }
365 else
366 {
367 nValue = GetCoreValue( *m_xMtrFldAmount, eUnit );
368 }
** CID 1667085: Integer handling issues (INTEGER_OVERFLOW)
/svx/source/dialog/_contdlg.cxx: 638 in
SvxSuperContourDlg::PipetteClickHdl(ContourWindow &)()
_____________________________________________________________________________________________
*** CID 1667085: Integer handling issues (INTEGER_OVERFLOW)
/svx/source/dialog/_contdlg.cxx: 638 in
SvxSuperContourDlg::PipetteClickHdl(ContourWindow &)()
632 const Color& rColor = rWnd.GetPipetteColor();
633
634 weld::WaitObject aWaitObj(&m_rDialog);
635
636 if( aGraphic.GetType() == GraphicType::Bitmap )
637 {
>>> CID 1667085: Integer handling issues (INTEGER_OVERFLOW)
>>> Expression "this->m_xMtfTolerance->get_value(FieldUnit::PERCENT) *
>>> 255L", where "this->m_xMtfTolerance->get_value(FieldUnit::PERCENT)" is
>>> known to be equal to -9223372036854775808, overflows the type of
>>> "this->m_xMtfTolerance->get_value(FieldUnit::PERCENT) * 255L", which is
>>> type "long".
638 const tools::Long nTol =
static_cast<tools::Long>(m_xMtfTolerance->get_value(FieldUnit::PERCENT) * 255 /
100);
639
640 AlphaMask aMask =
aGraphic.GetBitmap().CreateColorBitmap().CreateAlphaMask( rColor, nTol );
641
642 if( aGraphic.IsTransparent() )
643 aMask.AlphaCombineOr(
aGraphic.GetBitmap().CreateAlphaMask() );
** CID 1667084: Integer handling issues (INTEGER_OVERFLOW)
/cui/source/tabpages/tpgradnt.cxx: 216 in
SvxGradientTabPage::FillItemSet(SfxItemSet *)()
_____________________________________________________________________________________________
*** CID 1667084: Integer handling issues (INTEGER_OVERFLOW)
/cui/source/tabpages/tpgradnt.cxx: 216 in
SvxGradientTabPage::FillItemSet(SfxItemSet *)()
210 pBGradient->SetSteps(nValue);
211 rSet->Put( XFillGradientItem( aString, *pBGradient ) );
212 }
213 else
214 // gradient was passed (unidentified)
215 {
>>> CID 1667084: Integer handling issues (INTEGER_OVERFLOW)
>>> Expression "this->m_xMtrAngle->get_value(FieldUnit::NONE) * 10L", where
>>> "this->m_xMtrAngle->get_value(FieldUnit::NONE)" is known to be equal to
>>> -9223372036854775808, overflows the type of
>>> "this->m_xMtrAngle->get_value(FieldUnit::NONE) * 10L", which is type "long".
216 pBGradient.reset(new basegfx::BGradient(
217 createColorStops(),
218
static_cast<css::awt::GradientStyle>(m_xLbGradientType->get_active()),
219
Degree10(static_cast<sal_Int16>(m_xMtrAngle->get_value(FieldUnit::NONE) * 10)),
// should be changed in resource
220
static_cast<sal_uInt16>(m_xMtrCenterX->get_value(FieldUnit::NONE)),
221
static_cast<sal_uInt16>(m_xMtrCenterY->get_value(FieldUnit::NONE)),
________________________________________________________________________________________________________
To view the defects in Coverity Scan visit,
https://scan.coverity.com/projects/libreoffice?tab=overview