mirror of
https://github.com/XRPLF/rippled.git
synced 2025-12-06 17:27:55 +00:00
Using return value of fwrite in posix_logger.h
Summary: Was causing error(warning) in third-party saying unused result Test Plan: make Reviewers: sheki, dhruba Reviewed By: dhruba Differential Revision: https://reviews.facebook.net/D9447
This commit is contained in:
@@ -111,11 +111,12 @@ class PosixLogger : public Logger {
|
||||
}
|
||||
#endif
|
||||
|
||||
fwrite(base, 1, write_size, file_);
|
||||
fflush(file_);
|
||||
|
||||
log_size_ += write_size;
|
||||
|
||||
size_t sz = fwrite(base, 1, write_size, file_);
|
||||
assert(sz == write_size);
|
||||
if (sz > 0) {
|
||||
fflush(file_);
|
||||
log_size_ += write_size;
|
||||
}
|
||||
if (base != buffer) {
|
||||
delete[] base;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user