diff options
author | Tushar Bende <tushar.bende@synerzip.com> | 2013-11-14 20:04:23 +0530 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2013-11-15 09:57:16 +0000 |
commit | 8f7c127c4be32a91052ea962aafd0af8a1645714 (patch) | |
tree | 5b0fb1bc9547dca1e735276f31126d1a7bb267ad /sw/source/filter/writer/wrtswtbl.cxx | |
parent | 20075205724ede61c35bcbf4781e3f7bf5811a78 (diff) |
Fix for LibreOffice crash during Document RoundTrip
Description: Some Documents were crashing LO During Roundtrip.
This was because of setting wrong gridSpan value during export.
Conflicts:
sw/qa/extras/ooxmlexport/ooxmlexport.cxx
Change-Id: Ibcb6d4f00520500a98c16eb40dec3b052ad6b3f9
Reviewed-on: https://gerrit.libreoffice.org/6672
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'sw/source/filter/writer/wrtswtbl.cxx')
-rw-r--r-- | sw/source/filter/writer/wrtswtbl.cxx | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/sw/source/filter/writer/wrtswtbl.cxx b/sw/source/filter/writer/wrtswtbl.cxx index c75de62d7a46..18d489689995 100644 --- a/sw/source/filter/writer/wrtswtbl.cxx +++ b/sw/source/filter/writer/wrtswtbl.cxx @@ -651,7 +651,11 @@ void SwWriteTable::FillTableRowsCols( long nStartRPos, sal_uInt16 nStartRow, SwWriteTableCol aSrchCol( nCPos ); SwWriteTableCols::const_iterator it = aCols.find( &aSrchCol ); OSL_ENSURE( it != aCols.end(), "missing column" ); - nCol = it - aCols.begin(); + if(it != aCols.end()) + { + // if find fails for some nCPos value then it used to set nCol value with size of aCols. + nCol = it - aCols.begin(); + } if( !ShouldExpandSub( pBox, bSubExpanded, nDepth ) ) { |