From b4e0f7625486e381f0d8f6854fdfb6ab7847b5c6 Mon Sep 17 00:00:00 2001 From: tnozaki Date: Thu, 13 May 2010 17:52:11 +0000 Subject: [PATCH] cast isblank(3)'s argument to unsigned char. --- factor/factor.c | 6 +++--- number/number.c | 6 +++--- primes/primes.c | 6 +++--- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/factor/factor.c b/factor/factor.c index d383f555..cc6c8b98 100644 --- a/factor/factor.c +++ b/factor/factor.c @@ -1,4 +1,4 @@ -/* $NetBSD: factor.c,v 1.22 2010/04/28 18:04:31 drochner Exp $ */ +/* $NetBSD: factor.c,v 1.23 2010/05/13 17:52:11 tnozaki Exp $ */ /* * Copyright (c) 1989, 1993 @@ -42,7 +42,7 @@ __COPYRIGHT("@(#) Copyright (c) 1989, 1993\ #if 0 static char sccsid[] = "@(#)factor.c 8.4 (Berkeley) 5/4/95"; #else -__RCSID("$NetBSD: factor.c,v 1.22 2010/04/28 18:04:31 drochner Exp $"); +__RCSID("$NetBSD: factor.c,v 1.23 2010/05/13 17:52:11 tnozaki Exp $"); #endif #endif /* not lint */ @@ -164,7 +164,7 @@ main(int argc, char *argv[]) err(1, "stdin"); exit (0); } - for (p = buf; isblank(*p); ++p); + for (p = buf; isblank((unsigned char)*p); ++p); if (*p == '\n' || *p == '\0') continue; if (*p == '-') diff --git a/number/number.c b/number/number.c index 60331f35..3d28455c 100644 --- a/number/number.c +++ b/number/number.c @@ -1,4 +1,4 @@ -/* $NetBSD: number.c,v 1.13 2009/08/12 08:12:20 dholland Exp $ */ +/* $NetBSD: number.c,v 1.14 2010/05/13 17:52:11 tnozaki Exp $ */ /* * Copyright (c) 1988, 1993, 1994 @@ -39,7 +39,7 @@ __COPYRIGHT("@(#) Copyright (c) 1988, 1993, 1994\ #if 0 static char sccsid[] = "@(#)number.c 8.3 (Berkeley) 5/4/95"; #else -__RCSID("$NetBSD: number.c,v 1.13 2009/08/12 08:12:20 dholland Exp $"); +__RCSID("$NetBSD: number.c,v 1.14 2010/05/13 17:52:11 tnozaki Exp $"); #endif #endif /* not lint */ @@ -134,7 +134,7 @@ convert(line) flen = 0; fraction = NULL; for (p = line; *p != '\0' && *p != '\n'; ++p) { - if (isblank(*p)) { + if (isblank((unsigned char)*p)) { if (p == line) { ++line; continue; diff --git a/primes/primes.c b/primes/primes.c index 60b65904..c8c6ea58 100644 --- a/primes/primes.c +++ b/primes/primes.c @@ -1,4 +1,4 @@ -/* $NetBSD: primes.c,v 1.17 2009/08/12 08:25:27 dholland Exp $ */ +/* $NetBSD: primes.c,v 1.18 2010/05/13 17:52:12 tnozaki Exp $ */ /* * Copyright (c) 1989, 1993 @@ -42,7 +42,7 @@ __COPYRIGHT("@(#) Copyright (c) 1989, 1993\ #if 0 static char sccsid[] = "@(#)primes.c 8.5 (Berkeley) 5/10/95"; #else -__RCSID("$NetBSD: primes.c,v 1.17 2009/08/12 08:25:27 dholland Exp $"); +__RCSID("$NetBSD: primes.c,v 1.18 2010/05/13 17:52:12 tnozaki Exp $"); #endif #endif /* not lint */ @@ -199,7 +199,7 @@ read_num_buf(void) err(1, "stdin"); exit(0); } - for (p = buf; isblank(*p); ++p); + for (p = buf; isblank((unsigned char)*p); ++p); if (*p == '\n' || *p == '\0') continue; if (*p == '-') -- 2.47.1