This is the mail archive of the
libstdc++@gcc.gnu.org
mailing list for the libstdc++ project.
RE: [v3] fix libstdc++/9827
- From: Pétur Runólfsson <peturr02 at ru dot is>
- To: "Jerry Quinn" <jlquinn at optonline dot net>,<libstdc++ at gcc dot gnu dot org>,<gcc-patches at gcc dot gnu dot org>
- Date: Tue, 25 Feb 2003 17:27:44 -0000
- Subject: RE: [v3] fix libstdc++/9827
> ostreambuf_iterator&
> _M_put(const _CharT* __ws, streamsize __len)
> {
> - this->_M_sbuf->sputn(__ws, __len);
> + if (this->_M_sbuf->sputn(__ws, __len) != __len)
> + _M_failed = true;
> return *this;
> }
I believe there is still a problem here: You should only call sputn
if failed() returns false.
Petur