[vte] terminal: Adjust variable type
- From: Christian Persch <chpe src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vte] terminal: Adjust variable type
- Date: Mon, 11 May 2020 22:23:18 +0000 (UTC)
commit 78031f362af3933a70a40ad9e3ea5cd3ba2df590
Author: Christian Persch <chpe src gnome org>
Date: Tue May 12 00:22:59 2020 +0200
terminal: Adjust variable type
AFAICT the computation will never exceed the int range, but
simply use auto here to be sure, and remove a FIXME.
https://gitlab.gnome.org/GNOME/vte/-/issues/244#note_796941
src/vte.cc | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
---
diff --git a/src/vte.cc b/src/vte.cc
index e8825f5b..034c3062 100644
--- a/src/vte.cc
+++ b/src/vte.cc
@@ -2090,8 +2090,7 @@ Terminal::ensure_row()
VteRowData *row;
/* Figure out how many rows we need to add. */
- //FIXMEchpe use long, not int
- int delta = m_screen->cursor.row - _vte_ring_next(m_screen->row_data) + 1;
+ auto const delta = m_screen->cursor.row - _vte_ring_next(m_screen->row_data) + 1;
if (delta > 0) {
row = insert_rows(delta);
adjust_adjustments();
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]