From 07b7aae81582d07a5ef04ce3daf465cc232d8daf Mon Sep 17 00:00:00 2001 From: Jeff Epler Date: Fri, 11 Oct 2024 11:40:44 -0500 Subject: [PATCH] fix initial tabulations --- hl-vt100/src/lw_terminal_vt100.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/hl-vt100/src/lw_terminal_vt100.c b/hl-vt100/src/lw_terminal_vt100.c index 6769f2f..c089a56 100644 --- a/hl-vt100/src/lw_terminal_vt100.c +++ b/hl-vt100/src/lw_terminal_vt100.c @@ -1184,8 +1184,9 @@ struct lw_terminal_vt100 *lw_terminal_vt100_init(void *user_data, this->tabulations = malloc(132); if (this->tabulations == NULL) goto free_frozen_screen; - if (this->tabulations == NULL) - return NULL; + for(int i=0; i<132; i++) { + this->tabulations[i] = (i && i % 8 == 0) ? '|' : '-'; + } this->margin_top = 0; this->margin_bottom = this->height - 1; this->selected_charset = 1;