Bash-4.1 distribution source

This commit is contained in:
Chet Ramey
2011-11-21 20:51:19 -05:00
parent 89a92869e5
commit 0001803f0b
252 changed files with 51563 additions and 37176 deletions

View File

@@ -77,7 +77,7 @@ _rl_find_next_mbchar_internal (string, seed, count, find_non_zero)
char *string;
int seed, count, find_non_zero;
{
size_t tmp;
size_t tmp, len;
mbstate_t ps;
int point;
wchar_t wc;
@@ -99,7 +99,10 @@ _rl_find_next_mbchar_internal (string, seed, count, find_non_zero)
while (count > 0)
{
tmp = mbrtowc (&wc, string+point, strlen(string + point), &ps);
len = strlen (string + point);
if (len == 0)
break;
tmp = mbrtowc (&wc, string+point, len, &ps);
if (MB_INVALIDCH ((size_t)tmp))
{
/* invalid bytes. assume a byte represents a character */