Home | Info | Community | Development | myReactOS | Contact Us
traits_type::eof()
[protected, virtual]
Reimplemented from basic_streambuf< char, char_traits< char > >.
Definition at line 203 of file stdio_streambuf.cpp.
{ // Write the existing buffer, without writing any additional character. if (c == traits_type::eof()) { // Do we have a buffer to write? ptrdiff_t unwritten = this->pptr() - this->pbase(); if (unwritten != 0) { _STLP_VENDOR_CSTD::fflush(_M_file); // Test if the write succeeded. if (this->pptr() - this->pbase() < unwritten) return traits_type::not_eof(c); else return traits_type::eof(); } // We always succeed if we don't have to do anything. else return traits_type::not_eof(c); } // Write the character c, and whatever else might be in the buffer. else { #ifdef _STLP_WCE int result = fputc(c, _M_file); #else int result = putc(c, _M_file); #endif return result != EOF ? result : traits_type::eof(); } }