]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
common: use more efficient vector for stack
authorPatrick Donnelly <pdonnell@redhat.com>
Sat, 17 Feb 2024 01:43:06 +0000 (20:43 -0500)
committerPatrick Donnelly <pdonnell@redhat.com>
Fri, 22 Mar 2024 15:38:01 +0000 (11:38 -0400)
Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
(cherry picked from commit 770ab517c2b05045c09af3d0a56b6446bd20bb58)

src/common/Formatter.h

index 1919b018a67c6681afd2c798f81730c38748479a..cddfdab0c4f0ffbdddabd850f6db9033f2c8a46e 100644 (file)
@@ -13,6 +13,7 @@
 #include <stdarg.h>
 #include <sstream>
 #include <map>
+#include <vector>
 
 namespace ceph {
 
@@ -204,7 +205,7 @@ namespace ceph {
     copyable_sstream m_ss;
     copyable_sstream m_pending_string;
     std::string m_pending_name;
-    std::list<json_formatter_stack_entry_d> m_stack;
+    std::vector<json_formatter_stack_entry_d> m_stack;
     bool m_is_pending_string;
     bool m_line_break_enabled = false;
   };