Module: wine Branch: master Commit: b0cf3214775ad4d6be0913072cb7f02e51ffb6a6 URL: http://source.winehq.org/git/wine.git/?a=commit;h=b0cf3214775ad4d6be0913072c...
Author: Piotr Caban piotr@codeweavers.com Date: Wed Aug 28 15:14:48 2013 +0200
msvcp60: Fix basic_filebuf::_Init implementation.
---
dlls/msvcp60/ios.c | 9 ++++++--- 1 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/dlls/msvcp60/ios.c b/dlls/msvcp60/ios.c index 7e87607..e985e07 100644 --- a/dlls/msvcp60/ios.c +++ b/dlls/msvcp60/ios.c @@ -2310,7 +2310,8 @@ void __thiscall basic_filebuf_char__Init(basic_filebuf_char *this, FILE *file, b this->cvt = NULL; this->state0 = basic_filebuf_char__Init__Stinit; this->state = basic_filebuf_char__Init__Stinit; - this->str = NULL; + if(which == INITFL_new) + this->str = NULL; this->close = (which == INITFL_open); this->file = file;
@@ -2802,7 +2803,8 @@ static void basic_filebuf_wchar__Init(basic_filebuf_wchar *this, FILE *file, bas this->cvt = NULL; this->state0 = basic_filebuf_short__Init__Stinit; this->state = basic_filebuf_short__Init__Stinit; - this->str = NULL; + if(which == INITFL_new) + this->str = NULL; this->close = (which == INITFL_open); this->file = file;
@@ -2819,7 +2821,8 @@ void __thiscall basic_filebuf_short__Init(basic_filebuf_wchar *this, FILE *file, this->cvt = NULL; this->state0 = basic_filebuf_short__Init__Stinit; this->state = basic_filebuf_short__Init__Stinit; - this->str = NULL; + if(which == INITFL_new) + this->str = NULL; this->close = (which == INITFL_open); this->file = file;