mirror of
git://git.sv.gnu.org/nano.git
synced 2025-03-20 00:12:58 +03:00
yet another cleanup
git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@2655 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
This commit is contained in:
parent
356d2482c5
commit
42af2216fe
@ -805,7 +805,7 @@ char *mbstrchr(const char *s, char *c)
|
|||||||
char *s_mb = charalloc(MB_CUR_MAX);
|
char *s_mb = charalloc(MB_CUR_MAX);
|
||||||
const char *q = s;
|
const char *q = s;
|
||||||
wchar_t ws, wc;
|
wchar_t ws, wc;
|
||||||
int s_mb_len, c_mb_len = mbtowc(&wc, c, MB_CUR_MAX);
|
int c_mb_len = mbtowc(&wc, c, MB_CUR_MAX);
|
||||||
|
|
||||||
if (c_mb_len <= 0) {
|
if (c_mb_len <= 0) {
|
||||||
mbtowc(NULL, NULL, 0);
|
mbtowc(NULL, NULL, 0);
|
||||||
@ -813,7 +813,7 @@ char *mbstrchr(const char *s, char *c)
|
|||||||
}
|
}
|
||||||
|
|
||||||
while (*s != '\0') {
|
while (*s != '\0') {
|
||||||
s_mb_len = parse_mbchar(s, s_mb, NULL, NULL);
|
int s_mb_len = parse_mbchar(s, s_mb, NULL, NULL);
|
||||||
|
|
||||||
if (mbtowc(&ws, s_mb, s_mb_len) <= 0) {
|
if (mbtowc(&ws, s_mb, s_mb_len) <= 0) {
|
||||||
mbtowc(NULL, NULL, 0);
|
mbtowc(NULL, NULL, 0);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user