mirror of
https://github.com/postgres/postgres.git
synced 2025-07-27 12:41:57 +03:00
Ensure that all uses of <ctype.h> functions are applied to unsigned-char
values, whether the local char type is signed or not. This is necessary for portability. Per discussion on pghackers around 9/16/00.
This commit is contained in:
@ -28,9 +28,10 @@
|
||||
#define DIGIT(val) ((val) + '0')
|
||||
#define ISOCTAL(c) (((c) >= '0') && ((c) <= '7'))
|
||||
#ifndef ISO8859
|
||||
#define NOTPRINTABLE(c) (!isprint(c))
|
||||
#define NOTPRINTABLE(c) (!isprint((unsigned char) (c)))
|
||||
#else
|
||||
#define NOTPRINTABLE(c) (!isprint(c) && ((c) < 0xa0))
|
||||
#define NOTPRINTABLE(c) (!isprint((unsigned char) (c)) && \
|
||||
((unsigned char) (c) < (unsigned char) 0xa0))
|
||||
#endif
|
||||
|
||||
/*
|
||||
|
Reference in New Issue
Block a user