summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2010-05-26 20:41:58 +0000
committerPaul Davis <paul@linuxaudiosystems.com>2010-05-26 20:41:58 +0000
commit32593eb61c3babe07e6570b8d096c02f0aefdc0d (patch)
treeeb4696b28b88450967df4bcfd122468736397bd4
parentae8b97416abb6ec7282c0b16e5842364b59928fc (diff)
logic error in AutomationEvent::cut_copy_clear() when deciding whether to add an extra final point to an automation list
git-svn-id: svn://localhost/ardour2/branches/2.0-ongoing@7169 d708f5d6-7413-0410-9779-e7cbd77b26cf
-rw-r--r--libs/ardour/automation_event.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/libs/ardour/automation_event.cc b/libs/ardour/automation_event.cc
index 28b7dde050..f1cdd52c87 100644
--- a/libs/ardour/automation_event.cc
+++ b/libs/ardour/automation_event.cc
@@ -1147,11 +1147,11 @@ AutomationList::cut_copy_clear (double start, double end, int op)
/* only add a boundary point if there is a point after "end"
*/
- if (op == 0 && (e != events.end() || end < (*e)->when)) { // cut
+ if (op == 0 && (e != events.end() && end < (*e)->when)) { // cut
events.insert (e, point_factory (end, end_value));
}
- if (op != 2 && (e != events.end() || end < (*e)->when)) { // cut/copy
+ if (op != 2 && (e != events.end() && end < (*e)->when)) { // cut/copy
nal->events.push_back (point_factory (end - start, end_value));
}
}