From 9587e11f97026b15d392f2aa8e5e8c9284cd054b Mon Sep 17 00:00:00 2001 From: Tim Mayberry Date: Fri, 26 Aug 2016 20:57:51 +1000 Subject: [PATCH] Use XMLNode::set_property API in PBD::Undo class --- libs/pbd/undo.cc | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/libs/pbd/undo.cc b/libs/pbd/undo.cc index a11edbda47..d816afa28b 100644 --- a/libs/pbd/undo.cc +++ b/libs/pbd/undo.cc @@ -135,13 +135,9 @@ UndoTransaction::redo () XMLNode &UndoTransaction::get_state() { XMLNode *node = new XMLNode ("UndoTransaction"); - stringstream ss; - ss << _timestamp.tv_sec; - node->add_property("tv_sec", ss.str()); - ss.str(""); - ss << _timestamp.tv_usec; - node->add_property("tv_usec", ss.str()); - node->add_property("name", _name); + node->set_property("tv_sec", (int64_t)_timestamp.tv_sec); + node->set_property("tv_usec", (int64_t)_timestamp.tv_usec); + node->set_property("name", _name); list::iterator it; for (it=actions.begin(); it!=actions.end(); it++)