From 675054edb06e52df7f81a988026c9ab44ceb9392 Mon Sep 17 00:00:00 2001 From: gad Date: Tue, 1 Jun 2004 23:27:11 +0000 Subject: Try to change the isdigitch() macro to something that Bruce won't roll his eyes at quite so much... (actually someone else pointed this out to me a long time ago, but apparently I never fixed it) --- bin/ps/ps.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'bin') diff --git a/bin/ps/ps.c b/bin/ps/ps.c index 14e360a..58bad10 100644 --- a/bin/ps/ps.c +++ b/bin/ps/ps.c @@ -85,10 +85,10 @@ __FBSDID("$FreeBSD$"); #endif /* - * isdigit is defined to work on an 'int', in the range 0 to 255, plus EOF. - * Define a wrapper which can take 'char', either signed or unsigned. + * isdigit takes an `int', but expects values in the range of unsigned char. + * This wrapper ensures that values from a 'char' end up in the correct range. */ -#define isdigitch(Anychar) isdigit(((int) Anychar) & 255) +#define isdigitch(Anychar) isdigit((u_char)(Anychar)) int cflag; /* -c */ int eval; /* Exit value */ -- cgit v1.1