diff --git a/lib/recorder.cpp b/lib/recorder.cpp index 449039adff..e9af745cdf 100644 --- a/lib/recorder.cpp +++ b/lib/recorder.cpp @@ -93,12 +93,12 @@ void RecWriter::record(const std::string& val) { return ; } - record_ofs << swss::getTimestamp() << "|" << val << std::endl; if (isRotate()) { setRotate(false); logfileReopen(); } + record_ofs << swss::getTimestamp() << "|" << val << std::endl; }