diff --git a/include/fmt/os.h b/include/fmt/os.h index 7796260a..2379347b 100644 --- a/include/fmt/os.h +++ b/include/fmt/os.h @@ -395,6 +395,7 @@ class ostream : private detail::buffer { public: ostream(ostream&& other) : file_(std::move(other.file_)) { + set(other.data(), other.capacity()); other.set(nullptr, 0); } ~ostream() {