Squashed 'subtree/rabit/' changes from f52daf9..c679671
c679671 fix io style git-subtree-dir: subtree/rabit git-subtree-split: c67967161e9863a7da5554ab695c5f798d3ebc67
This commit is contained in:
parent
20da8bbe50
commit
44fd329b02
@ -345,13 +345,13 @@ inline int ostream::OutBuf::sync(void) {
|
|||||||
if (stream_ == NULL) return -1;
|
if (stream_ == NULL) return -1;
|
||||||
std::ptrdiff_t n = pptr() - pbase();
|
std::ptrdiff_t n = pptr() - pbase();
|
||||||
stream_->Write(pbase(), n);
|
stream_->Write(pbase(), n);
|
||||||
this->pbump(-n);
|
this->pbump(-static_cast<int>(n));
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
inline int ostream::OutBuf::overflow(int c) {
|
inline int ostream::OutBuf::overflow(int c) {
|
||||||
*(this->pptr()) = c;
|
*(this->pptr()) = c;
|
||||||
std::ptrdiff_t n = pptr() - pbase();
|
std::ptrdiff_t n = pptr() - pbase();
|
||||||
this->pbump(-n);
|
this->pbump(-static_cast<int>(n));
|
||||||
if (c == EOF) {
|
if (c == EOF) {
|
||||||
stream_->Write(pbase(), n);
|
stream_->Write(pbase(), n);
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user