diff options
author | Tim Mayberry <mojofunk@gmail.com> | 2017-03-10 22:59:58 +1000 |
---|---|---|
committer | Tim Mayberry <mojofunk@gmail.com> | 2017-03-10 22:59:58 +1000 |
commit | 151956589057175c4775e339b9b200f30a741874 (patch) | |
tree | 21bd5a33676bea8197769bac3e6be3cc0041af4e /gtk2_ardour/editor_ops.cc | |
parent | f21111d7df446ccf7ce512b6b97a738b0e2e9ead (diff) |
Fix crash when removing time from track with automation
Resolves : #7287
Diffstat (limited to 'gtk2_ardour/editor_ops.cc')
-rw-r--r-- | gtk2_ardour/editor_ops.cc | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/gtk2_ardour/editor_ops.cc b/gtk2_ardour/editor_ops.cc index 2b8a5fd018..4eef1058af 100644 --- a/gtk2_ardour/editor_ops.cc +++ b/gtk2_ardour/editor_ops.cc @@ -7656,16 +7656,17 @@ Editor::remove_time (framepos_t pos, framecnt_t frames, InsertTimeOption opt, XMLNode &before = pl->get_state(); + if (!in_command) { + begin_reversible_command (_("remove time")); + in_command = true; + } + std::list<AudioRange> rl; AudioRange ar(pos, pos+frames, 0); rl.push_back(ar); pl->cut (rl); pl->shift (pos, -frames, true, ignore_music_glue); - if (!in_command) { - begin_reversible_command (_("remove time")); - in_command = true; - } XMLNode &after = pl->get_state(); _session->add_command (new MementoCommand<Playlist> (*pl, &before, &after)); |