Checking in a infinite loop fix done by Vidur, not part of the build.

This commit is contained in:
jst%netscape.com 2000-09-10 23:24:10 +00:00
parent 023a68e714
commit 90cc9d88a4
2 changed files with 14 additions and 2 deletions

View File

@ -374,7 +374,13 @@ nsHTMLContentSerializer::AppendToStringWrapped(const nsAReadableString& aStr,
if (start < 0)
start = 0;
indx = aStr.FindChar(PRUnichar(' '), strOffset + start);
if ((strOffset + start) < length) {
indx = aStr.FindChar(PRUnichar(' '), strOffset + start);
}
else {
indx = kNotFound;
}
// if there is no break than just add the entire string
if (indx == kNotFound)
{

View File

@ -374,7 +374,13 @@ nsHTMLContentSerializer::AppendToStringWrapped(const nsAReadableString& aStr,
if (start < 0)
start = 0;
indx = aStr.FindChar(PRUnichar(' '), strOffset + start);
if ((strOffset + start) < length) {
indx = aStr.FindChar(PRUnichar(' '), strOffset + start);
}
else {
indx = kNotFound;
}
// if there is no break than just add the entire string
if (indx == kNotFound)
{