Fix: appendTwoWords cannot handle MAX_WORD_LENGTH-chars word.

Bug: 9892258
Change-Id: Ib4ef7850c8fc8b1d99d594bb7ef68ce645f0f1f3
main
Keisuke Kuroynagi 2013-07-31 16:58:09 +09:00
parent f8c1aefd90
commit 11a431fca6
1 changed files with 1 additions and 1 deletions

View File

@ -150,7 +150,7 @@ namespace latinime {
} }
actualLength1 = i + 1; actualLength1 = i + 1;
} }
actualLength1 = min(actualLength1, MAX_WORD_LENGTH - actualLength0 - 1); actualLength1 = min(actualLength1, MAX_WORD_LENGTH - actualLength0);
memcpy(&dest[actualLength0], src1, actualLength1 * sizeof(dest[0])); memcpy(&dest[actualLength0], src1, actualLength1 * sizeof(dest[0]));
return actualLength0 + actualLength1; return actualLength0 + actualLength1;
} }