diff options
author | Philip Guenther <guenther@cvs.openbsd.org> | 2015-10-01 02:32:08 +0000 |
---|---|---|
committer | Philip Guenther <guenther@cvs.openbsd.org> | 2015-10-01 02:32:08 +0000 |
commit | 00087c13f0a1ce0076c3caba4ffccc6416ff4c9c (patch) | |
tree | 66f8aa81a14106ae7a8a841a20ee0fadf11fe68e /lib/libc/locale | |
parent | 44d895a4f0e0d0bba54c64bb34c61b56c36710da (diff) |
Eliminate the last of the LINTEDn and PRINTFLIKEn comments. In one
case, by deleting some useless '& of an array' we also eliminate the need
for the casts which prompted the original lint warnings
ok deraadt@
Diffstat (limited to 'lib/libc/locale')
-rw-r--r-- | lib/libc/locale/_wcstod.h | 5 | ||||
-rw-r--r-- | lib/libc/locale/_wcstol.h | 3 | ||||
-rw-r--r-- | lib/libc/locale/_wcstoul.h | 3 | ||||
-rw-r--r-- | lib/libc/locale/runeglue.c | 14 |
4 files changed, 7 insertions, 18 deletions
diff --git a/lib/libc/locale/_wcstod.h b/lib/libc/locale/_wcstod.h index de9de77e086..27f375f1589 100644 --- a/lib/libc/locale/_wcstod.h +++ b/lib/libc/locale/_wcstod.h @@ -1,4 +1,4 @@ -/* $OpenBSD: _wcstod.h,v 1.3 2015/09/12 16:23:14 guenther Exp $ */ +/* $OpenBSD: _wcstod.h,v 1.4 2015/10/01 02:32:07 guenther Exp $ */ /* $NetBSD: wcstod.c,v 1.4 2001/10/28 12:08:43 yamt Exp $ */ /*- @@ -134,8 +134,6 @@ match: const char *s = buf; memset(&st, 0, sizeof(st)); size = mbsnrtowcs(NULL, &s, end - buf, 0, &st); - - /* LINTED bad interface */ *endptr = (wchar_t*)start + size; } @@ -146,7 +144,6 @@ match: fail: if (endptr) - /* LINTED bad interface */ *endptr = (wchar_t*)nptr; return 0; diff --git a/lib/libc/locale/_wcstol.h b/lib/libc/locale/_wcstol.h index e105b0100ff..1b60a3a4532 100644 --- a/lib/libc/locale/_wcstol.h +++ b/lib/libc/locale/_wcstol.h @@ -1,4 +1,4 @@ -/* $OpenBSD: _wcstol.h,v 1.2 2015/09/12 16:23:14 guenther Exp $ */ +/* $OpenBSD: _wcstol.h,v 1.3 2015/10/01 02:32:07 guenther Exp $ */ /* $NetBSD: _wcstol.h,v 1.2 2003/08/07 16:43:03 agc Exp $ */ /*- @@ -130,7 +130,6 @@ FUNCNAME(const wchar_t *nptr, wchar_t **endptr, int base) } } if (endptr != 0) - /* LINTED interface specification */ *endptr = (wchar_t *)(any ? s - 1 : nptr); return (acc); } diff --git a/lib/libc/locale/_wcstoul.h b/lib/libc/locale/_wcstoul.h index c42442295d5..159b22b2945 100644 --- a/lib/libc/locale/_wcstoul.h +++ b/lib/libc/locale/_wcstoul.h @@ -1,4 +1,4 @@ -/* $OpenBSD: _wcstoul.h,v 1.2 2015/09/12 16:23:14 guenther Exp $ */ +/* $OpenBSD: _wcstoul.h,v 1.3 2015/10/01 02:32:07 guenther Exp $ */ /* $NetBSD: _wcstoul.h,v 1.2 2003/08/07 16:43:03 agc Exp $ */ /* @@ -110,7 +110,6 @@ FUNCNAME(const wchar_t *nptr, wchar_t **endptr, int base) if (neg && any > 0) acc = -acc; if (endptr != 0) - /* LINTED interface specification */ *endptr = (wchar_t *)(any ? s - 1 : nptr); return (acc); } diff --git a/lib/libc/locale/runeglue.c b/lib/libc/locale/runeglue.c index 5ce28100952..33e3a2bc523 100644 --- a/lib/libc/locale/runeglue.c +++ b/lib/libc/locale/runeglue.c @@ -1,4 +1,4 @@ -/* $OpenBSD: runeglue.c,v 1.3 2012/12/05 23:20:00 deraadt Exp $ */ +/* $OpenBSD: runeglue.c,v 1.4 2015/10/01 02:32:07 guenther Exp $ */ /* $NetBSD: runeglue.c,v 1.10 2003/03/10 21:18:49 tshiozak Exp $ */ /*- @@ -117,15 +117,9 @@ void __install_currentrunelocale_ctype() { if (_CurrentRuneLocale->rl_tabs != NULL) { - /* LINTED const cast */ - _ctype_ = (const unsigned char *) - &(_CurrentRuneLocale->rl_tabs->ctype_tab); - /* LINTED const cast */ - _toupper_tab_ = (const short *) - &(_CurrentRuneLocale->rl_tabs->toupper_tab); - /* LINTED const cast */ - _tolower_tab_ = (const short *) - &(_CurrentRuneLocale->rl_tabs->tolower_tab); + _ctype_ = _CurrentRuneLocale->rl_tabs->ctype_tab; + _toupper_tab_ = _CurrentRuneLocale->rl_tabs->toupper_tab; + _tolower_tab_ = _CurrentRuneLocale->rl_tabs->tolower_tab; } else { _ctype_ = _C_ctype_; _toupper_tab_ = _C_toupper_; |