From b2fafc5cbfb504a474834fb4200f4bce2e91a1c5 Mon Sep 17 00:00:00 2001 From: Chad Loder Date: Sun, 27 Nov 2005 20:03:07 +0000 Subject: Add a cast for (size_t)-1 because we know what we're doing, the ISO std. says this is what we're supposed to return. Makes lint happy. OK deraadt, espie --- lib/libc/locale/mbrtowc_sb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/libc/locale/mbrtowc_sb.c b/lib/libc/locale/mbrtowc_sb.c index 9516656f5ae..e47e06ae019 100644 --- a/lib/libc/locale/mbrtowc_sb.c +++ b/lib/libc/locale/mbrtowc_sb.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mbrtowc_sb.c,v 1.3 2005/08/11 20:51:56 espie Exp $ */ +/* $OpenBSD: mbrtowc_sb.c,v 1.4 2005/11/27 20:03:06 cloder Exp $ */ /* $NetBSD: multibyte_sb.c,v 1.4 2003/08/07 16:43:04 agc Exp $ */ /* @@ -46,7 +46,7 @@ mbrtowc(wchar_t *pwc, const char *s, size_t n, mbstate_t *ps) if (s == NULL) return 0; if (n == 0) - return -1; + return (size_t)-1; if (pwc) *pwc = (wchar_t)(unsigned char)*s; return (*s != '\0'); -- cgit v1.2.3