aboutsummaryrefslogtreecommitdiff
path: root/newlib/libc/stdio/fputws.c
diff options
context:
space:
mode:
authorCorinna Vinschen <corinna@vinschen.de>2023-11-20 20:46:14 +0100
committerCorinna Vinschen <corinna@vinschen.de>2023-11-20 20:59:13 +0100
commit09119463a1445be498f8a6ce3834d462361c7dd3 (patch)
treead5e3e893c9ec6b07b032ee9c3768ba509e402c9 /newlib/libc/stdio/fputws.c
parentbc986b7ff668aa98372fc4e885307339e7ab3f51 (diff)
downloadnewlib-09119463a1445be498f8a6ce3834d462361c7dd3.zip
newlib-09119463a1445be498f8a6ce3834d462361c7dd3.tar.gz
newlib-09119463a1445be498f8a6ce3834d462361c7dd3.tar.bz2
stdio: split byte- and wide-char-oriented low-level output functions
Introduce function __swbufw_r and macros/inline-functions called __swputc_r. Call these functions/macros exclusively from wide-char functions. This allows to set and test the stream orientation correctly even if output is only performed using byte-oriented macros from stdio.h. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
Diffstat (limited to 'newlib/libc/stdio/fputws.c')
-rw-r--r--newlib/libc/stdio/fputws.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/newlib/libc/stdio/fputws.c b/newlib/libc/stdio/fputws.c
index a9ac9d6..d696383 100644
--- a/newlib/libc/stdio/fputws.c
+++ b/newlib/libc/stdio/fputws.c
@@ -143,7 +143,7 @@ error:
goto error;
while (i < nbytes)
{
- if (__sputc_r (ptr, buf[i], fp) == EOF)
+ if (__swputc_r (ptr, buf[i], fp) == EOF)
goto error;
i++;
}