summaryrefslogtreecommitdiffstats
path: root/lib/libc/stdio/fputwc.c
diff options
context:
space:
mode:
authortjr <tjr@FreeBSD.org>2004-07-20 08:27:27 +0000
committertjr <tjr@FreeBSD.org>2004-07-20 08:27:27 +0000
commit04d8be5a378ec2e51b6a040e7bddd966377e4c5a (patch)
tree7c7db31d3361d73eb1f35c4a144266372f699890 /lib/libc/stdio/fputwc.c
parenta93503b19666f94ff77327b7dbdf285cc888f46d (diff)
downloadFreeBSD-src-04d8be5a378ec2e51b6a040e7bddd966377e4c5a.zip
FreeBSD-src-04d8be5a378ec2e51b6a040e7bddd966377e4c5a.tar.gz
Call __mbrtowc() and __wcrtomb() directly instead of taking detours
through mbrtowc() and wcrtomb().
Diffstat (limited to 'lib/libc/stdio/fputwc.c')
-rw-r--r--lib/libc/stdio/fputwc.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/libc/stdio/fputwc.c b/lib/libc/stdio/fputwc.c
index 3f3984d..0848b74 100644
--- a/lib/libc/stdio/fputwc.c
+++ b/lib/libc/stdio/fputwc.c
@@ -36,6 +36,7 @@ __FBSDID("$FreeBSD$");
#include "un-namespace.h"
#include "libc_private.h"
#include "local.h"
+#include "mblocal.h"
/*
* Non-MT-safe version.
@@ -55,7 +56,7 @@ __fputwc(wchar_t wc, FILE *fp)
*buf = (unsigned char)wc;
len = 1;
} else {
- if ((len = wcrtomb(buf, wc, &fp->_extra->mbstate)) ==
+ if ((len = __wcrtomb(buf, wc, &fp->_extra->mbstate)) ==
(size_t)-1) {
fp->_flags |= __SERR;
return (WEOF);
OpenPOWER on IntegriCloud