From 7ae7416cc585a8fb27740f1fecf0ce54fe0b4535 Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Thu, 17 Feb 2011 14:05:21 +0000 Subject: [PATCH] Minor cleanups. git-svn-id: svn://localhost/ardour2/branches/3.0@8879 d708f5d6-7413-0410-9779-e7cbd77b26cf --- libs/ardour/session_state.cc | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/libs/ardour/session_state.cc b/libs/ardour/session_state.cc index 675c7e679c..9a359e1b05 100644 --- a/libs/ardour/session_state.cc +++ b/libs/ardour/session_state.cc @@ -523,7 +523,6 @@ Session::ensure_subdirs () int Session::create (const string& mix_template, BusProfile* bus_profile) { - if (g_mkdir_with_parents (_path.c_str(), 0755) < 0) { error << string_compose(_("Session: cannot create session folder \"%1\" (%2)"), _path, strerror (errno)) << endmsg; return -1; @@ -538,14 +537,14 @@ Session::create (const string& mix_template, BusProfile* bus_profile) ifstream in(in_path.c_str()); - if (in){ + if (in) { string out_path = _path; out_path += _name; out_path += statefile_suffix; ofstream out(out_path.c_str()); - if (out){ + if (out) { out << in.rdbuf(); _is_new = false; return 0; @@ -1216,7 +1215,7 @@ Session::set_state (const XMLNode& node, int version) _state_of_the_state = StateOfTheState (_state_of_the_state|CannotSave); - if (node.name() != X_("Session")){ + if (node.name() != X_("Session")) { fatal << _("programming error: Session: incorrect XML node sent to set_state()") << endmsg; return -1; } @@ -2009,7 +2008,7 @@ Session::save_template (string template_name) } if (!tree.write (template_file_path.to_string())) { - error << _("mix template not saved") << endmsg; + error << _("template not saved") << endmsg; return -1; } @@ -2588,7 +2587,7 @@ Session::cleanup_regions () uint32_t used = playlists->region_use_count (audio_region); - if (used == 0 && !audio_region->automatic()){ + if (used == 0 && !audio_region->automatic()) { RegionFactory::map_remove(i->second); } }