summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEgmont Koblinger <egmont@gmail.com>2017-04-24 13:48:55 +0200
committerEgmont Koblinger <egmont@gmail.com>2017-04-24 13:48:55 +0200
commitca7f577a8ff92804d087145a1efad3fb6be2fefc (patch)
tree3115531970b05ea19391a598bf419693e513aa0c
parenta26a60b8e564968b61716f0d2e52e17cd9362413 (diff)
downloadvte-ca7f577a8ff92804d087145a1efad3fb6be2fefc.tar.gz
ring: Tiny code cleanup: maintain GString integrity
-rw-r--r--src/ring.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/ring.cc b/src/ring.cc
index e0906108..36d82e12 100644
--- a/src/ring.cc
+++ b/src/ring.cc
@@ -236,7 +236,7 @@ _vte_ring_thaw_row (VteRing *ring, gulong position, VteRowData *row, gboolean do
record = records[0];
if (G_LIKELY (buffer->len && buffer->str[buffer->len - 1] == '\n'))
- buffer->len--;
+ g_string_truncate (buffer, buffer->len - 1);
else
row->attr.soft_wrapped = TRUE;