summaryrefslogtreecommitdiff
path: root/libs/ardour
diff options
context:
space:
mode:
Diffstat (limited to 'libs/ardour')
-rw-r--r--libs/ardour/source.cc17
1 files changed, 10 insertions, 7 deletions
diff --git a/libs/ardour/source.cc b/libs/ardour/source.cc
index e5aa759670..c299588f3c 100644
--- a/libs/ardour/source.cc
+++ b/libs/ardour/source.cc
@@ -110,7 +110,7 @@ Source::get_state ()
}
int
-Source::set_state (const XMLNode& node, int /*version*/)
+Source::set_state (const XMLNode& node, int version)
{
const XMLProperty* prop;
@@ -146,12 +146,15 @@ Source::set_state (const XMLNode& node, int /*version*/)
_flags = Flag (_flags | Destructive);
}
- /* a source with an XML node must necessarily already exist,
- and therefore cannot be removable/writable etc. etc.
- */
- if (!(_flags & Destructive)) {
- _flags = Flag (_flags & ~(Writable|Removable|RemovableIfEmpty|RemoveAtDestroy|CanRename));
- }
+ if (version < 3000) {
+ /* a source with an XML node must necessarily already exist,
+ and therefore cannot be removable/writable etc. etc.; 2.X
+ sometimes marks sources as removable which shouldn't be.
+ */
+ if (!(_flags & Destructive)) {
+ _flags = Flag (_flags & ~(Writable|Removable|RemovableIfEmpty|RemoveAtDestroy|CanRename));
+ }
+ }
return 0;
}