1
1
mirror of https://github.com/wez/wezterm.git synced 2024-11-27 02:25:28 +03:00

fix subtraction underflow

This commit is contained in:
Wez Furlong 2019-06-22 13:14:08 -07:00
parent 4c877d493f
commit 7751a85826

View File

@ -497,7 +497,7 @@ impl ClientSurfaceState {
// so that multiple clients have an opportunity to
// resync from a smaller delta
self.surface
.flush_changes_older_than(new_seq - (rows * cols * 2));
.flush_changes_older_than(new_seq.saturating_sub(rows * cols * 2));
(new_seq, changes)
}
}