Kevin Puetz : msvcp: Use fput[w]c in basic_filebuf_char_overflow.

Alexandre Julliard julliard at winehq.org
Thu Oct 3 16:44:00 CDT 2019


Module: wine
Branch: master
Commit: 925e56acff4e714364cbf3507f669aff570132b0
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=925e56acff4e714364cbf3507f669aff570132b0

Author: Kevin Puetz <PuetzKevinA at JohnDeere.com>
Date:   Thu Oct  3 18:06:42 2019 +0200

msvcp: Use fput[w]c in basic_filebuf_char_overflow.

Signed-off-by: Jacek Caban <jacek at codeweavers.com>
Signed-off-by: Piotr Caban <piotr at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/msvcp90/ios.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/dlls/msvcp90/ios.c b/dlls/msvcp90/ios.c
index 8e6884c8f9..84174e4f95 100644
--- a/dlls/msvcp90/ios.c
+++ b/dlls/msvcp90/ios.c
@@ -3374,7 +3374,7 @@ int __thiscall basic_filebuf_char_overflow(basic_filebuf_char *this, int c)
         return !c;
 
     if(!this->cvt)
-        return fwrite(&ch, sizeof(char), 1, this->file) ? c : EOF;
+        return fputc(ch, this->file);
 
     from_next = &ch;
     do {
@@ -4009,7 +4009,7 @@ unsigned short __thiscall basic_filebuf_wchar_overflow(basic_filebuf_wchar *this
         return !c;
 
     if(!this->cvt)
-        return fwrite(&ch, sizeof(wchar_t), 1, this->file) ? c : WEOF;
+        return fputwc(ch, this->file);
 
     from_next = &ch;
     do {




More information about the wine-cvs mailing list