possible fix for a valgrind reported illegal read
This commit is contained in:
parent
5f3cd26d02
commit
b7769a8f4b
@ -1789,9 +1789,9 @@ TempoMap::_get_tempo_and_meter (typename const_traits_t::tempo_point_type & tp,
|
|||||||
p = last_used;
|
p = last_used;
|
||||||
|
|
||||||
if (can_match) {
|
if (can_match) {
|
||||||
while (((*p).*method)() <= arg && p != endi) ++p;
|
while ((p != endi) && ((*p).*method)() <= arg) ++p;
|
||||||
} else {
|
} else {
|
||||||
while (((*p).*method)() < arg && p != endi) ++p;
|
while ((p != endi) && ((*p).*method)() < arg) ++p;
|
||||||
}
|
}
|
||||||
|
|
||||||
return p;
|
return p;
|
||||||
|
Loading…
Reference in New Issue
Block a user