Kaydet (Commit) b189726c authored tarafından Caolán McNamara's avatar Caolán McNamara

ofz#5942 Out of memory

when missing a glyph in a grapheme we set the whole grapheme as missing.  There
can be a huge long grapheme and iterating through each missing codepoint
results in the whole range pushed back repeatedly as missing.

Change-Id: Ib7c283389ee2357eb3b4264c78e558955ebad1eb
Reviewed-on: https://gerrit.libreoffice.org/49223Tested-by: 's avatarJenkins <ci@libreoffice.org>
Reviewed-by: 's avatarCaolán McNamara <caolanm@redhat.com>
Tested-by: 's avatarCaolán McNamara <caolanm@redhat.com>
üst b05a3198
...@@ -270,6 +270,12 @@ void ImplLayoutRuns::AddRun( int nCharPos0, int nCharPos1, bool bRTL ) ...@@ -270,6 +270,12 @@ void ImplLayoutRuns::AddRun( int nCharPos0, int nCharPos1, bool bRTL )
nCharPos1 = nTemp; nCharPos1 = nTemp;
} }
if (maRuns.size() >= 2 && nCharPos0 == maRuns[maRuns.size() - 2] && nCharPos1 == maRuns[maRuns.size() - 1])
{
//this run is the same as the last
return;
}
// append new run // append new run
maRuns.push_back( nCharPos0 ); maRuns.push_back( nCharPos0 );
maRuns.push_back( nCharPos1 ); maRuns.push_back( nCharPos1 );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment