diff --git a/include/ldap_pvt_uc.h b/include/ldap_pvt_uc.h index 5b4bcc06ed..bfd236ef05 100644 --- a/include/ldap_pvt_uc.h +++ b/include/ldap_pvt_uc.h @@ -82,7 +82,7 @@ LDAP_F (char *) ldap_utf8_strpbrk( const char* str, const char *set); LDAP_F (char*) ldap_utf8_strtok( char* sp, const char* sep, char **last); /* Optimizations */ -#define LDAP_UTF8_ISASCII(p) ( * (const unsigned char *) (p) < 0x100 ) +#define LDAP_UTF8_ISASCII(p) ( * (const unsigned char *) (p) < 0x80 ) #define LDAP_UTF8_CHARLEN(p) ( LDAP_UTF8_ISASCII(p) \ ? 1 : ldap_utf8_charlen((p)) ) #define LDAP_UTF8_OFFSET(p) ( LDAP_UTF8_ISASCII(p) \ diff --git a/libraries/libldap/utf-8.c b/libraries/libldap/utf-8.c index 1523b7b4a4..70734d7504 100644 --- a/libraries/libldap/utf-8.c +++ b/libraries/libldap/utf-8.c @@ -29,7 +29,7 @@ #include "ldap_defaults.h" #undef ISASCII -#define ISASCII(uc) ((uc) < 0x100) +#define ISASCII(uc) ((uc) < 0x80) /* * Basic UTF-8 routines @@ -264,7 +264,7 @@ int ldap_utf8_copy( char* dst, const char *src ) /* * UTF-8 ctype routines - * Only deals with characters < 0x100 (ie: US-ASCII) + * Only deals with characters < 0x80 (ie: US-ASCII) */ int ldap_utf8_isascii( const char * p )