diff --git a/logging/env_logger.h b/logging/env_logger.h index 8164945cf..fc9b24550 100644 --- a/logging/env_logger.h +++ b/logging/env_logger.h @@ -76,6 +76,7 @@ class EnvLogger : public Logger { if (flush_pending_) { flush_pending_ = false; file_.Flush().PermitUncheckedError(); + file_.reset_seen_error(); } last_flush_micros_ = clock_->NowMicros(); } @@ -162,6 +163,7 @@ class EnvLogger : public Logger { FileOpGuard guard(*this); // We will ignore any error returned by Append(). file_.Append(Slice(base, p - base)).PermitUncheckedError(); + file_.reset_seen_error(); flush_pending_ = true; const uint64_t now_micros = clock_->NowMicros(); if (now_micros - last_flush_micros_ >= flush_every_seconds_ * 1000000) {