mirror of
https://github.com/ONLYOFFICE/core.git
synced 2026-07-16 00:59:02 +08:00
for bug #63199
This commit is contained in:
@ -37,7 +37,7 @@ namespace DocFileFormat
|
||||
ParagraphPropertyExceptions::ParagraphPropertyExceptions() : PropertyExceptions(), istd(0)
|
||||
{
|
||||
}
|
||||
ParagraphPropertyExceptions::ParagraphPropertyExceptions( const std::list<SinglePropertyModifier>& grpprl ):
|
||||
ParagraphPropertyExceptions::ParagraphPropertyExceptions( const std::vector<SinglePropertyModifier>& grpprl ):
|
||||
PropertyExceptions( grpprl ), istd(0)
|
||||
{
|
||||
}
|
||||
@ -238,13 +238,11 @@ namespace DocFileFormat
|
||||
|
||||
//There is a SPRM that points to an offset in the data stream,
|
||||
//where a list of SPRM is saved.
|
||||
for ( std::list<SinglePropertyModifier>::iterator iter = grpprl->begin(); iter != grpprl->end(); iter++ )
|
||||
for ( std::vector<SinglePropertyModifier>::iterator iter = grpprl->begin(); iter != grpprl->end(); iter++ )
|
||||
{
|
||||
SinglePropertyModifier sprm( *iter );
|
||||
|
||||
if( ( sprm.OpCode == sprmPHugePapx ) || ( (int)sprm.OpCode == 0x6646 ) )
|
||||
if( (iter->OpCode == sprmPHugePapx ) || ( (int)iter->OpCode == 0x6646 ) )
|
||||
{
|
||||
unsigned int fc = FormatUtils::BytesToUInt32( sprm.Arguments, 0, sprm.argumentsSize );
|
||||
unsigned int fc = FormatUtils::BytesToUInt32(iter->Arguments, 0, iter->argumentsSize );
|
||||
reader = new VirtualStreamReader( dataStream, (int)fc, nWordVersion);
|
||||
|
||||
//parse the size of the external grpprl
|
||||
@ -261,14 +259,20 @@ namespace DocFileFormat
|
||||
|
||||
//assign the external grpprl
|
||||
RELEASEOBJECT( grpprl );
|
||||
grpprl = new std::list<SinglePropertyModifier>( *(externalPx.grpprl) );
|
||||
grpprl = new std::vector<SinglePropertyModifier>( *(externalPx.grpprl) );
|
||||
|
||||
RELEASEARRAYOBJECTS(grpprlBytes);
|
||||
RELEASEOBJECT(reader)
|
||||
|
||||
//remove the sprmPHugePapx
|
||||
grpprl->remove( sprm );
|
||||
|
||||
RELEASEARRAYOBJECTS( grpprlBytes );
|
||||
RELEASEOBJECT( reader )
|
||||
|
||||
for (std::vector<SinglePropertyModifier>::iterator iter2 = grpprl->begin(); iter2 != grpprl->end(); iter2++)
|
||||
{
|
||||
if ((iter2->OpCode == sprmPHugePapx) || ((int)iter2->OpCode == 0x6646))
|
||||
{
|
||||
grpprl->erase(iter2);
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user