Skip to content

Commit

Permalink
fix stack overflow
Browse files Browse the repository at this point in the history
  • Loading branch information
Uriopass committed Dec 5, 2023
1 parent d4d2fd6 commit 947edd5
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion geom/src/skeleton.rs
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,9 @@ impl PartialOrd for Event {

impl Ord for Event {
fn cmp(&self, other: &Self) -> Ordering {
self.partial_cmp(other).unwrap_or(Ordering::Equal)
self.distance()
.partial_cmp(&other.distance())
.unwrap_or(Ordering::Equal)
}
}

Expand Down

0 comments on commit 947edd5

Please sign in to comment.