Progress on mingw driver
This commit is contained in:
@@ -166,6 +166,9 @@ void StreamBuffer::write_bytes(const char *s, int64_t len) {
|
||||
write_cursor_ += len;
|
||||
}
|
||||
|
||||
void StreamBuffer::write_bytes(const std::string &s) {
|
||||
write_bytes(s.c_str(), s.size());
|
||||
}
|
||||
|
||||
const char *StreamBuffer::read_bytes(int64_t bytes) {
|
||||
check_available(bytes);
|
||||
@@ -395,11 +398,11 @@ void StreamBuffer::overwrite_uint64(int64_t write_count_after, uint64_t vv) {
|
||||
memcpy(target, &v, 8);
|
||||
}
|
||||
|
||||
bool StreamBuffer::at_eof() {
|
||||
bool StreamBuffer::empty() {
|
||||
return (read_cursor_ == write_cursor_);
|
||||
}
|
||||
|
||||
void StreamBuffer::verify_eof() {
|
||||
void StreamBuffer::verify_empty() {
|
||||
if (read_cursor_ != write_cursor_) {
|
||||
throw StreamCorruption();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user