aboutsummaryrefslogtreecommitdiff
path: root/vt.c
diff options
context:
space:
mode:
authorCraig Barnes <craigbarnes@protonmail.com>2020-08-08 19:34:30 +0000
committerCraig Barnes <craigbarnes@protonmail.com>2020-08-08 19:37:57 +0000
commit7a77958ba20c2b344be5e66e69e2f212a4bbf6b3 (patch)
treecdb8191177f5f9ca69ea7858f9543f36fcbcf616 /vt.c
parentchangelog: add birger to 'contributers' for the upcoming release (diff)
Convert most dynamic allocations to use functions from xmalloc.h
Diffstat (limited to 'vt.c')
-rw-r--r--vt.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/vt.c b/vt.c
index f25f26be..d114b87b 100644
--- a/vt.c
+++ b/vt.c
@@ -13,6 +13,7 @@
#include "grid.h"
#include "osc.h"
#include "util.h"
+#include "xmalloc.h"
#define UNHANDLED() LOG_DBG("unhandled: %s", esc_as_string(term, final))
@@ -649,7 +650,7 @@ action_utf8_print(struct terminal *term, wchar_t wc)
if (term->composed_count < CELL_COMB_CHARS_HI) {
term->composed_count++;
- term->composed = realloc(term->composed, term->composed_count * sizeof(term->composed[0]));
+ term->composed = xrealloc(term->composed, term->composed_count * sizeof(term->composed[0]));
term->composed[term->composed_count - 1] = new_cc;
term_print(term, CELL_COMB_CHARS_LO + term->composed_count - 1, base_width);