diff options
author | Garrett D'Amore <garrett@nexenta.com> | 2010-07-30 07:06:32 -0700 |
---|---|---|
committer | Garrett D'Amore <garrett@nexenta.com> | 2010-07-30 07:06:32 -0700 |
commit | 4297a3b0d0a35d80f86fff155e288e885a100e6d (patch) | |
tree | bba873e6335d31404bbac128ffa6ebe126b43900 /usr/src/lib/libc/port/stdio/vwscanf.c | |
parent | 969bc941052c29943dfb40d55089dc56fa46be57 (diff) | |
download | illumos-gate-4297a3b0d0a35d80f86fff155e288e885a100e6d.tar.gz |
2 We need a fully open libc (no libc_i18n)
Reviewd by: garrett@nexenta.com
Approved by: garrett@nexenta.com
Diffstat (limited to 'usr/src/lib/libc/port/stdio/vwscanf.c')
-rw-r--r-- | usr/src/lib/libc/port/stdio/vwscanf.c | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/usr/src/lib/libc/port/stdio/vwscanf.c b/usr/src/lib/libc/port/stdio/vwscanf.c index 7448e6ffad..76cfabf4ae 100644 --- a/usr/src/lib/libc/port/stdio/vwscanf.c +++ b/usr/src/lib/libc/port/stdio/vwscanf.c @@ -54,11 +54,8 @@ vwscanf(const wchar_t *fmt, va_list ap) FLOCKFILE(lk, stdin); - if (_set_orientation_wide(stdin, NULL, NULL, 0) == -1) { - errno = EBADF; - FUNLOCKFILE(lk); - return (EOF); - } + if (GET_NO_MODE(stdin)) + _setorientation(stdin, _WC_MODE); #ifdef _C89_INTMAX32 ret = __wdoscan_u(stdin, fmt, ap, _F_INTMAX32); @@ -81,11 +78,8 @@ vfwscanf(FILE *iop, const wchar_t *fmt, va_list ap) FLOCKFILE(lk, iop); - if (_set_orientation_wide(iop, NULL, NULL, 0) == -1) { - errno = EBADF; - FUNLOCKFILE(lk); - return (EOF); - } + if (GET_NO_MODE(iop)) + _setorientation(iop, _WC_MODE); #ifdef _C89_INTMAX32 |