Fix non-BMP unicode character lenght counting.