clean up plugin-ui meter layout
[ardour.git] / gtk2_ardour / time_selection.cc
index 419d82dbccfde06c06c0c9788803f3ea573538f3..a0f33e8c99fd0db7aabe36275e8d3799a46e03f7 100644 (file)
@@ -103,5 +103,9 @@ TimeSelection::end_frame ()
 framecnt_t
 TimeSelection::length()
 {
+       if (empty()) {
+               return 0;
+       }
+
        return end_frame() - start() + 1;
 }