@ -390,7 +390,7 @@ getNextFlagFromString(IspellDict *Conf, const char **sflagset, char *sflag)
* sflagset = next ;
while ( * * sflagset )
{
if ( t_ isdigit( * sflagset ) )
if ( isdigit ( ( unsigned char ) * * sflagset ) )
{
if ( ! met_comma )
ereport ( ERROR ,
@ -408,7 +408,7 @@ getNextFlagFromString(IspellDict *Conf, const char **sflagset, char *sflag)
* sflagset ) ) ) ;
met_comma = true ;
}
else if ( ! t_ isspace( * sflagset ) )
else if ( ! isspace ( ( unsigned char ) * * sflagset ) )
{
ereport ( ERROR ,
( errcode ( ERRCODE_CONFIG_FILE_ERROR ) ,
@ -542,7 +542,7 @@ NIImportDictionary(IspellDict *Conf, const char *filename)
while ( * s )
{
/* we allow only single encoded flags for faster works */
if ( pg_mblen ( s ) = = 1 & & t_ isprint( s ) & & ! t_ isspace( s ) )
if ( pg_mblen ( s ) = = 1 & & isprint ( ( unsigned char ) * s ) & & ! isspace ( ( unsigned char ) * s ) )
s + + ;
else
{
@ -558,7 +558,7 @@ NIImportDictionary(IspellDict *Conf, const char *filename)
s = line ;
while ( * s )
{
if ( t_ isspace( s ) )
if ( isspace ( ( unsigned char ) * s ) )
{
* s = ' \0 ' ;
break ;
@ -799,7 +799,7 @@ get_nextfield(char **str, char *next)
{
if ( t_iseq ( * str , ' # ' ) )
return false ;
else if ( ! t_ isspace( * str ) )
else if ( ! isspace ( ( unsigned char ) * * str ) )
{
int clen = pg_mblen ( * str ) ;
@ -814,7 +814,7 @@ get_nextfield(char **str, char *next)
}
else /* state == PAE_INMASK */
{
if ( t_ isspace( * str ) )
if ( isspace ( ( unsigned char ) * * str ) )
{
* next = ' \0 ' ;
return true ;
@ -925,7 +925,7 @@ parse_affentry(char *str, char *mask, char *find, char *repl)
{
if ( t_iseq ( str , ' # ' ) )
return false ;
else if ( ! t_ isspace( str ) )
else if ( ! isspace ( ( unsigned char ) * str ) )
{
COPYCHAR ( pmask , str ) ;
pmask + = pg_mblen ( str ) ;
@ -939,7 +939,7 @@ parse_affentry(char *str, char *mask, char *find, char *repl)
* pmask = ' \0 ' ;
state = PAE_WAIT_FIND ;
}
else if ( ! t_ isspace( str ) )
else if ( ! isspace ( ( unsigned char ) * str ) )
{
COPYCHAR ( pmask , str ) ;
pmask + = pg_mblen ( str ) ;
@ -957,7 +957,7 @@ parse_affentry(char *str, char *mask, char *find, char *repl)
prepl + = pg_mblen ( str ) ;
state = PAE_INREPL ;
}
else if ( ! t_ isspace( str ) )
else if ( ! isspace ( ( unsigned char ) * str ) )
ereport ( ERROR ,
( errcode ( ERRCODE_CONFIG_FILE_ERROR ) ,
errmsg ( " syntax error " ) ) ) ;
@ -974,7 +974,7 @@ parse_affentry(char *str, char *mask, char *find, char *repl)
COPYCHAR ( pfind , str ) ;
pfind + = pg_mblen ( str ) ;
}
else if ( ! t_ isspace( str ) )
else if ( ! isspace ( ( unsigned char ) * str ) )
ereport ( ERROR ,
( errcode ( ERRCODE_CONFIG_FILE_ERROR ) ,
errmsg ( " syntax error " ) ) ) ;
@ -991,7 +991,7 @@ parse_affentry(char *str, char *mask, char *find, char *repl)
prepl + = pg_mblen ( str ) ;
state = PAE_INREPL ;
}
else if ( ! t_ isspace( str ) )
else if ( ! isspace ( ( unsigned char ) * str ) )
ereport ( ERROR ,
( errcode ( ERRCODE_CONFIG_FILE_ERROR ) ,
errmsg ( " syntax error " ) ) ) ;
@ -1008,7 +1008,7 @@ parse_affentry(char *str, char *mask, char *find, char *repl)
COPYCHAR ( prepl , str ) ;
prepl + = pg_mblen ( str ) ;
}
else if ( ! t_ isspace( str ) )
else if ( ! isspace ( ( unsigned char ) * str ) )
ereport ( ERROR ,
( errcode ( ERRCODE_CONFIG_FILE_ERROR ) ,
errmsg ( " syntax error " ) ) ) ;
@ -1070,7 +1070,7 @@ addCompoundAffixFlagValue(IspellDict *Conf, char *s, uint32 val)
char * sflag ;
int clen ;
while ( * s & & t_ isspace( s ) )
while ( * s & & isspace ( ( unsigned char ) * s ) )
s + = pg_mblen ( s ) ;
if ( ! * s )
@ -1080,7 +1080,7 @@ addCompoundAffixFlagValue(IspellDict *Conf, char *s, uint32 val)
/* Get flag without \n */
sflag = sbuf ;
while ( * s & & ! t_ isspace( s ) & & * s ! = ' \n ' )
while ( * s & & ! isspace ( ( unsigned char ) * s ) & & * s ! = ' \n ' )
{
clen = pg_mblen ( s ) ;
COPYCHAR ( sflag , s ) ;
@ -1225,7 +1225,7 @@ NIImportOOAffixes(IspellDict *Conf, const char *filename)
while ( ( recoded = tsearch_readline ( & trst ) ) ! = NULL )
{
if ( * recoded = = ' \0 ' | | t_ isspace( recoded ) | | t_iseq ( recoded , ' # ' ) )
if ( * recoded = = ' \0 ' | | isspace ( ( unsigned char ) * recoded ) | | t_iseq ( recoded , ' # ' ) )
{
pfree ( recoded ) ;
continue ;
@ -1262,7 +1262,7 @@ NIImportOOAffixes(IspellDict *Conf, const char *filename)
{
char * s = recoded + strlen ( " FLAG " ) ;
while ( * s & & t_ isspace( s ) )
while ( * s & & isspace ( ( unsigned char ) * s ) )
s + = pg_mblen ( s ) ;
if ( * s )
@ -1298,7 +1298,7 @@ NIImportOOAffixes(IspellDict *Conf, const char *filename)
{
int fields_read ;
if ( * recoded = = ' \0 ' | | t_ isspace( recoded ) | | t_iseq ( recoded , ' # ' ) )
if ( * recoded = = ' \0 ' | | isspace ( ( unsigned char ) * recoded ) | | t_iseq ( recoded , ' # ' ) )
goto nextline ;
fields_read = parse_ooaffentry ( recoded , type , sflag , find , repl , mask ) ;
@ -1461,9 +1461,9 @@ NIImportAffixes(IspellDict *Conf, const char *filename)
s = findchar2 ( recoded , ' l ' , ' L ' ) ;
if ( s )
{
while ( * s & & ! t_ isspace( s ) )
while ( * s & & ! isspace ( ( unsigned char ) * s ) )
s + = pg_mblen ( s ) ;
while ( * s & & t_ isspace( s ) )
while ( * s & & isspace ( ( unsigned char ) * s ) )
s + = pg_mblen ( s ) ;
if ( * s & & pg_mblen ( s ) = = 1 )
@ -1494,7 +1494,7 @@ NIImportAffixes(IspellDict *Conf, const char *filename)
s = recoded + 4 ; /* we need non-lowercased string */
flagflags = 0 ;
while ( * s & & t_ isspace( s ) )
while ( * s & & isspace ( ( unsigned char ) * s ) )
s + = pg_mblen ( s ) ;
if ( * s = = ' * ' )
@ -1523,7 +1523,7 @@ NIImportAffixes(IspellDict *Conf, const char *filename)
s + + ;
if ( * s = = ' \0 ' | | * s = = ' # ' | | * s = = ' \n ' | | * s = = ' : ' | |
t_ isspace( s ) )
isspace ( ( unsigned char ) * s ) )
{
oldformat = true ;
goto nextline ;
@ -1750,7 +1750,7 @@ NISortDictionary(IspellDict *Conf)
( errcode ( ERRCODE_CONFIG_FILE_ERROR ) ,
errmsg ( " invalid affix alias \" %s \" " ,
Conf - > Spell [ i ] - > p . flag ) ) ) ;
if ( * end ! = ' \0 ' & & ! t_ isdigit( end ) & & ! t_ isspace( end ) )
if ( * end ! = ' \0 ' & & ! isdigit ( ( unsigned char ) * end ) & & ! isspace ( ( unsigned char ) * end ) )
ereport ( ERROR ,
( errcode ( ERRCODE_CONFIG_FILE_ERROR ) ,
errmsg ( " invalid affix alias \" %s \" " ,