summaryrefslogtreecommitdiff
path: root/libs
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2012-06-16 02:50:20 +0000
committerPaul Davis <paul@linuxaudiosystems.com>2012-06-16 02:50:20 +0000
commit0ea8ba3f560bd90dfc8e5401d370176d7aa66734 (patch)
treecc4d65ee3f0052f6d757a293723dc01ac415225d /libs
parenta8dd4ec8053d77a5501f16c2cc1bba24f82f1b95 (diff)
never try to remove state from a read-only session
git-svn-id: svn://localhost/ardour2/branches/3.0@12735 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs')
-rw-r--r--libs/ardour/session_state.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/libs/ardour/session_state.cc b/libs/ardour/session_state.cc
index 30f8571c01..347c4ee35b 100644
--- a/libs/ardour/session_state.cc
+++ b/libs/ardour/session_state.cc
@@ -675,7 +675,7 @@ Session::rename_state (string old_name, string new_name)
void
Session::remove_state (string snapshot_name)
{
- if (snapshot_name == _current_snapshot_name || snapshot_name == _name) {
+ if (!_writable || snapshot_name == _current_snapshot_name || snapshot_name == _name) {
// refuse to remove the current snapshot or the "main" one
return;
}