tweaks: don't bother special-casing non-UTF8 when checking for a blank
This code is almost never used; conciseness is the only consideration.master
parent
1c3953705c
commit
003ddc763e
11
src/chars.c
11
src/chars.c
|
@ -640,8 +640,6 @@ char *mbrevstrpbrk(const char *head, const char *accept, const char *pointer)
|
|||
* and FALSE otherwise. */
|
||||
bool has_blank_char(const char *s)
|
||||
{
|
||||
#ifdef ENABLE_UTF8
|
||||
if (use_utf8) {
|
||||
char symbol[MAXCHARLEN];
|
||||
|
||||
while (*s != '\0') {
|
||||
|
@ -650,15 +648,6 @@ bool has_blank_char(const char *s)
|
|||
if (is_blank_mbchar(symbol))
|
||||
return TRUE;
|
||||
}
|
||||
} else
|
||||
#endif
|
||||
{
|
||||
while (*s != '\0') {
|
||||
if (isblank((unsigned char)*s))
|
||||
return TRUE;
|
||||
s++;
|
||||
}
|
||||
}
|
||||
|
||||
return FALSE;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue