Increase ostream test coverage

This commit is contained in:
Vinnie Falco committed 2017-05-09 07:23:10 -07:00
1 parent 5631936106
commit 8363d869a0
2 files changed
+28 -10

No files matched your search

+2 -5
View File
@@ -54,10 +54,7 @@ operator<<(std::ostream& os,
//------------------------------------------------------------------------------
template<
class DynamicBuffer,
class CharT,
class Traits
>
class DynamicBuffer, class CharT, class Traits>
class ostream_buffer
: public std::basic_streambuf<CharT, Traits>
{
@@ -115,7 +112,7 @@ ostream_buffer<DynamicBuffer, CharT, Traits>::
overflow(int_type ch) ->
int_type
{
if(ch != traits_type::eof())
if(! Traits::eq_int_type(ch, Traits::eof()))
{
Traits::assign(*this->pptr(), ch);
flush(1);