diff options
author | Garrett D'Amore <garrett@nexenta.com> | 2010-08-01 17:20:38 -0700 |
---|---|---|
committer | Garrett D'Amore <garrett@nexenta.com> | 2010-08-01 17:20:38 -0700 |
commit | eda71b4a8fb1d0b34d0f08c47b43af49428d24c3 (patch) | |
tree | f939b179199ba43f17e159410cb4e5a59a0f1077 /usr/src/lib/libc/port/locale/mbftowc.c | |
parent | 5ffa97fa2ff163219bb606cc2bdf8bcd331ff77e (diff) | |
download | illumos-gate-eda71b4a8fb1d0b34d0f08c47b43af49428d24c3.tar.gz |
10 64-bit binaries busted
Reviewed by: estseg@gmail.com
Approved by: gdamore@nexenta.com
Diffstat (limited to 'usr/src/lib/libc/port/locale/mbftowc.c')
-rw-r--r-- | usr/src/lib/libc/port/locale/mbftowc.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr/src/lib/libc/port/locale/mbftowc.c b/usr/src/lib/libc/port/locale/mbftowc.c index 4f5a41a994..ed6514c406 100644 --- a/usr/src/lib/libc/port/locale/mbftowc.c +++ b/usr/src/lib/libc/port/locale/mbftowc.c @@ -51,7 +51,7 @@ _mbftowc(char *s, wchar_t *wc, int (*peek)(void), int *errorc) int c; mbstate_t mbs; char *start = s; - int cons = 0; + size_t cons = 0; for (;;) { c = peek(); @@ -65,11 +65,11 @@ _mbftowc(char *s, wchar_t *wc, int (*peek)(void), int *errorc) (void) memset(&mbs, 0, sizeof (mbs)); cons = mbrtowc(wc, start, s - start, &mbs); - if (cons >= 0) { + if ((int)cons >= 0) { /* fully translated character */ return (cons); } - if (cons == -2) { + if (cons == (size_t)-2) { /* incomplete, recycle */ continue; } |