commit bash-20130809 snapshot

This commit is contained in:
Chet Ramey
2013-09-12 08:54:38 -04:00
parent adbaf2b395
commit 9353cc0550
10 changed files with 97 additions and 37 deletions
+16 -3
View File
@@ -626,19 +626,32 @@ STRCOMPARE (p, pe, s, se)
{
int ret;
CHAR c1, c2;
int l1, l2;
l1 = pe - p;
l2 = se - s;
if (l1 != l2)
return (FNM_NOMATCH); /* unequal lengths, can't be identical */
c1 = *pe;
c2 = *se;
*pe = *se = '\0';
if (c1 != 0)
*pe = '\0';
if (c2 != 0)
*se = '\0';
#if HAVE_MULTIBYTE || defined (HAVE_STRCOLL)
ret = STRCOLL ((XCHAR *)p, (XCHAR *)s);
#else
ret = STRCMP ((XCHAR *)p, (XCHAR *)s);
#endif
*pe = c1;
*se = c2;
if (c1 != 0)
*pe = c1;
if (c2 != 0)
*se = c2;
return (ret == 0 ? ret : FNM_NOMATCH);
}
+1 -1
View File
@@ -1833,7 +1833,7 @@ _completion_loader()
@{
. "/etc/bash_completion.d/$1.sh" >/dev/null 2>&1 && return 124
@}
complete -D -F _completion_loader
complete -D -F _completion_loader -o bashdefault -o default
@end example
@node Programmable Completion Builtins
+1 -1
View File
@@ -393,7 +393,7 @@ _rl_strnicmp (string1, string2, count)
break;
s2++;
}
while (--count != 0)
while (--count != 0);
return (0);
}