From 3ea5fd5d91ae314eeeed468f583fa105d554970b Mon Sep 17 00:00:00 2001 From: Robin Gareus Date: Wed, 6 Jul 2022 01:44:54 +0200 Subject: [PATCH] Fix incorrect use of timepos_t::increment API --- gtk2_ardour/editor_ops.cc | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/gtk2_ardour/editor_ops.cc b/gtk2_ardour/editor_ops.cc index 13a64d3532..6b7ea0197c 100644 --- a/gtk2_ardour/editor_ops.cc +++ b/gtk2_ardour/editor_ops.cc @@ -356,7 +356,7 @@ Editor::move_range_selection_start_or_end_to_region_boundary (bool move_end, boo /* so we don't find the current region again */ if (dir > 0 || pos.is_positive()) { - pos.increment (); + pos = pos.increment (); } timepos_t const target = get_region_boundary (pos, dir, true, false); @@ -1204,8 +1204,9 @@ Editor::selected_marker_to_region_point (RegionPoint point, int32_t dir) pos = loc->start(); // so we don't find the current region again.. - if (dir>0 || pos>0) - pos.increment(); + if (dir > 0 || pos > 0) { + pos = pos.increment(); + } if (!selection->tracks.empty()) {