summaryrefslogtreecommitdiff
path: root/reportdesign
diff options
context:
space:
mode:
authorMike Kaganski <mike.kaganski@collabora.com>2019-04-14 13:58:14 +0300
committerMike Kaganski <mike.kaganski@collabora.com>2019-04-14 14:14:36 +0200
commit0869895063bd528893707cb74c6cf4c461fef066 (patch)
treebf47ccc71145f3ee387a5dafbaab9bc86b47a008 /reportdesign
parent4acae16f9252ada89fd530f1ca86edafc046bc07 (diff)
tdf#120703 PVS: Silence V522 warnings
V522 There might be dereferencing of a potential null pointer. Change-Id: Ie4bc74a734a6d5a73838a27e0d80cc8e51595839 Reviewed-on: https://gerrit.libreoffice.org/70730 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'reportdesign')
-rw-r--r--reportdesign/source/ui/report/ReportController.cxx2
1 files changed, 2 insertions, 0 deletions
diff --git a/reportdesign/source/ui/report/ReportController.cxx b/reportdesign/source/ui/report/ReportController.cxx
index d4c823561aa4..5e8e7e7d3b36 100644
--- a/reportdesign/source/ui/report/ReportController.cxx
+++ b/reportdesign/source/ui/report/ReportController.cxx
@@ -3470,6 +3470,7 @@ void OReportController::addPairControls(const Sequence< PropertyValue >& aArgs)
for(i = 0; i < SAL_N_ELEMENTS(pControl); ++i)
{
pObjs[i] = dynamic_cast<OUnoObject*>(pControl[i].get());
+ assert(pObjs[i]);
uno::Reference<beans::XPropertySet> xUnoProp(pObjs[i]->GetUnoControlModel(),uno::UNO_QUERY_THROW);
uno::Reference< report::XReportComponent> xShapeProp(pObjs[i]->getUnoShape(),uno::UNO_QUERY_THROW);
xUnoProp->setPropertyValue(PROPERTY_NAME,xShapeProp->getPropertyValue(PROPERTY_NAME));
@@ -3541,6 +3542,7 @@ void OReportController::addPairControls(const Sequence< PropertyValue >& aArgs)
xShapePropLabel->setPosition(aPosLabel);
}
OUnoObject* pObj = dynamic_cast<OUnoObject*>(pControl[0].get());
+ assert(pObj);
uno::Reference< report::XFixedText> xShapeProp(pObj->getUnoShape(),uno::UNO_QUERY_THROW);
xShapeProp->setName(xShapeProp->getName() + sDefaultName );