Permalink
Browse files

Merge pull request #3321 from Karlson2k/charsetconverter_fix_01

CharsetConverter: fix for logicalToVisualBiDi
  • Loading branch information...
2 parents 7b22691 + d273c32 commit 7f452883195f672f5237afbce8de09bd642ea72a @jmarshallnz jmarshallnz committed Sep 24, 2013
Showing with 2 additions and 0 deletions.
  1. +2 −0 xbmc/utils/CharsetConverter.cpp
View
2 xbmc/utils/CharsetConverter.cpp
@@ -299,6 +299,8 @@ static bool logicalToVisualBiDi(const std::string& stringSrc, std::string& strin
for (size_t i = 0; i < numLines; i++)
{
int sourceLen = lines[i].length();
+ if (sourceLen == 0)
+ continue;
// Convert from the selected charset to Unicode
FriBidiChar* logical = (FriBidiChar*) malloc((sourceLen + 1) * sizeof(FriBidiChar));

0 comments on commit 7f45288

Please sign in to comment.