diff options
| author | thorpej <thorpej@NetBSD.org> | 2002-11-11 01:12:04 +0000 |
|---|---|---|
| committer | thorpej <thorpej@NetBSD.org> | 2002-11-11 01:12:04 +0000 |
| commit | 20b98814a91fcb97123aace9915fff9e4ddbbc3f (patch) | |
| tree | 1acaec3c91215c7574b20dfbd660ddd73000e968 /lib/libc/string | |
| parent | 21353eb9a699be7f37071ae3f7cab52a7a6c1609 (diff) | |
Fix signed/unsigned comparison warnings.
Diffstat (limited to 'lib/libc/string')
| -rw-r--r-- | lib/libc/string/__strerror.c | 6 | ||||
| -rw-r--r-- | lib/libc/string/__strsignal.c | 6 |
2 files changed, 6 insertions, 6 deletions
diff --git a/lib/libc/string/__strerror.c b/lib/libc/string/__strerror.c index 31410e3a16a..48d42ccb5b0 100644 --- a/lib/libc/string/__strerror.c +++ b/lib/libc/string/__strerror.c @@ -1,4 +1,4 @@ -/* $NetBSD: __strerror.c,v 1.18 2002/02/13 08:05:12 yamt Exp $ */ +/* $NetBSD: __strerror.c,v 1.19 2002/11/11 01:12:04 thorpej Exp $ */ /* * Copyright (c) 1988 Regents of the University of California. @@ -38,7 +38,7 @@ #if 0 static char *sccsid = "@(#)strerror.c 5.6 (Berkeley) 5/4/91"; #else -__RCSID("$NetBSD: __strerror.c,v 1.18 2002/02/13 08:05:12 yamt Exp $"); +__RCSID("$NetBSD: __strerror.c,v 1.19 2002/11/11 01:12:04 thorpej Exp $"); #endif #endif /* LIBC_SCCS and not lint */ @@ -77,7 +77,7 @@ __strerror(num, buf, buflen) _DIAGASSERT(buf != NULL); errnum = num; /* convert to unsigned */ - if (errnum < sys_nerr) { + if (errnum < (unsigned int) sys_nerr) { #ifdef NLS (void)strncpy(buf, catgets(catd, 1, (int)errnum, sys_errlist[errnum]), buflen); diff --git a/lib/libc/string/__strsignal.c b/lib/libc/string/__strsignal.c index 4da45a0199e..230c7bc4fcf 100644 --- a/lib/libc/string/__strsignal.c +++ b/lib/libc/string/__strsignal.c @@ -1,4 +1,4 @@ -/* $NetBSD: __strsignal.c,v 1.21 2002/03/20 01:43:55 christos Exp $ */ +/* $NetBSD: __strsignal.c,v 1.22 2002/11/11 01:12:04 thorpej Exp $ */ /* * Copyright (c) 1988 Regents of the University of California. @@ -38,7 +38,7 @@ #if 0 static char *sccsid = "@(#)strerror.c 5.6 (Berkeley) 5/4/91"; #else -__RCSID("$NetBSD: __strsignal.c,v 1.21 2002/03/20 01:43:55 christos Exp $"); +__RCSID("$NetBSD: __strsignal.c,v 1.22 2002/11/11 01:12:04 thorpej Exp $"); #endif #endif /* LIBC_SCCS and not lint */ @@ -77,7 +77,7 @@ __strsignal(num, buf, buflen) _DIAGASSERT(buf != NULL); signum = num; /* convert to unsigned */ - if (signum < sys_nsig) { + if (signum < (unsigned int) sys_nsig) { #ifdef NLS (void)strncpy(buf, catgets(catd, 2, (int)signum, sys_siglist[signum]), NL_TEXTMAX); |
