summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorgad <gad@FreeBSD.org>2004-06-01 23:27:11 +0000
committergad <gad@FreeBSD.org>2004-06-01 23:27:11 +0000
commit675054edb06e52df7f81a988026c9ab44ceb9392 (patch)
tree709829d92714634625b5357644b66429835d8030 /bin
parenta4fd26fba2739b76643274396699eca9f810a614 (diff)
downloadFreeBSD-src-675054edb06e52df7f81a988026c9ab44ceb9392.zip
FreeBSD-src-675054edb06e52df7f81a988026c9ab44ceb9392.tar.gz
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)
Diffstat (limited to 'bin')
-rw-r--r--bin/ps/ps.c6
1 files changed, 3 insertions, 3 deletions
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 */
OpenPOWER on IntegriCloud