Always send timestamp in flow stat. Even if no data
authorIdo Barnea <[email protected]>
Sun, 13 Mar 2016 13:05:31 +0000 (15:05 +0200)
committerIdo Barnea <[email protected]>
Sun, 13 Mar 2016 13:05:31 +0000 (15:05 +0200)
src/flow_stat.cpp

index 1a083f8..dc03966 100644 (file)
@@ -640,11 +640,8 @@ bool CFlowStatRuleMgr::dump_json(std::string & json, bool baseline) {
     data_section["ts"]["freq"] = Json::Value::UInt64(os_get_hr_freq());
 
     if (m_user_id_map.is_empty()) {
-        if (baseline) {
-            json = writer.write(root);
-            return true;
-        } else
-            return false;
+        json = writer.write(root);
+        return true;
     }
 
     // read hw counters, and update