Prevent crash with long string of Indic characters. Bug 445711, r=pavlov

This commit is contained in:
Simon Montagu 2008-08-14 11:20:46 +03:00
parent 20c3dddf35
commit bb23c68e71
3 changed files with 13 additions and 1 deletions

View File

@ -0,0 +1,11 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/REC-html401-19991224/strict.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Tamil testcase</title>
</head>
<body>
<p>&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;&#x0BCC;</p>
</body>
</html>

View File

@ -1,2 +1,3 @@
load 306902-1.xml
load 383872-1.svg
load 445711.html

View File

@ -1332,9 +1332,9 @@ public:
mAttr.Elements(), &mNumGlyphs);
if (rv == E_OUTOFMEMORY) {
mMaxGlyphs *= 2;
mGlyphs.SetLength(mMaxGlyphs);
mAttr.SetLength(mMaxGlyphs);
mMaxGlyphs *= 2;
continue;
}