[Libreoffice-commits] core.git: editeng/source
Caolán McNamara (via logerrit)
logerrit at kemper.freedesktop.org
Tue Jun 1 11:47:32 UTC 2021
editeng/source/rtf/svxrtf.cxx | 29 +++++++++++++----------------
1 file changed, 13 insertions(+), 16 deletions(-)
New commits:
commit 00dac9306480cdca9be4e19ae3ff248df8b59c45
Author: Caolán McNamara <caolanm at redhat.com>
AuthorDate: Tue Jun 1 10:55:21 2021 +0100
Commit: Caolán McNamara <caolanm at redhat.com>
CommitDate: Tue Jun 1 13:46:43 2021 +0200
cid#1485154 try moving initialization into member init list
see if it has an effect on bogus "Uninitialized scalar variable"
Change-Id: I68d6a466f7fc9aa3412d50223dc53d6b60b721c5
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116527
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/editeng/source/rtf/svxrtf.cxx b/editeng/source/rtf/svxrtf.cxx
index b2cc406b9980..9c3f4cd2af17 100644
--- a/editeng/source/rtf/svxrtf.cxx
+++ b/editeng/source/rtf/svxrtf.cxx
@@ -914,23 +914,22 @@ const SfxItemSet& SvxRTFParser::GetRTFDefaults()
SvxRTFStyleType::SvxRTFStyleType( SfxItemPool& rPool, const sal_uInt16* pWhichRange )
- : aAttrSet( rPool, pWhichRange )
+ : aAttrSet(rPool, pWhichRange)
+ , nBasedOn(0)
+ , nOutlineNo(sal_uInt8(-1)) // not set
{
- nOutlineNo = sal_uInt8(-1); // not set
- nBasedOn = 0;
}
-
SvxRTFItemStackType::SvxRTFItemStackType(
SfxItemPool& rPool, const sal_uInt16* pWhichRange,
const EditPosition& rPos )
: aAttrSet( rPool, pWhichRange )
- , nStyleNo( 0 )
+ , mxStartNodeIdx(rPos.MakeNodeIdx())
+ , mxEndNodeIdx(mxStartNodeIdx)
+ , nSttCnt(rPos.GetCntIdx())
+ , nEndCnt(nSttCnt)
+ , nStyleNo(0)
{
- mxStartNodeIdx = rPos.MakeNodeIdx();
- nSttCnt = rPos.GetCntIdx();
- mxEndNodeIdx = mxStartNodeIdx;
- nEndCnt = nSttCnt;
}
SvxRTFItemStackType::SvxRTFItemStackType(
@@ -938,13 +937,12 @@ SvxRTFItemStackType::SvxRTFItemStackType(
const EditPosition& rPos,
bool const bCopyAttr )
: aAttrSet( *rCpy.aAttrSet.GetPool(), rCpy.aAttrSet.GetRanges() )
- , nStyleNo( rCpy.nStyleNo )
+ , mxStartNodeIdx(rPos.MakeNodeIdx())
+ , mxEndNodeIdx(mxStartNodeIdx)
+ , nSttCnt(rPos.GetCntIdx())
+ , nEndCnt(nSttCnt)
+ , nStyleNo(rCpy.nStyleNo)
{
- mxStartNodeIdx = rPos.MakeNodeIdx();
- nSttCnt = rPos.GetCntIdx();
- mxEndNodeIdx = mxStartNodeIdx;
- nEndCnt = nSttCnt;
-
aAttrSet.SetParent( &rCpy.aAttrSet );
if( bCopyAttr )
aAttrSet.Put( rCpy.aAttrSet );
@@ -1107,7 +1105,6 @@ void SvxRTFItemStackType::SetRTFDefaults( const SfxItemSet& rDefaults )
}
}
-
RTFPlainAttrMapIds::RTFPlainAttrMapIds( const SfxItemPool& rPool )
{
nCaseMap = rPool.GetTrueWhich( SID_ATTR_CHAR_CASEMAP, false );
More information about the Libreoffice-commits
mailing list