From e8ea7dc5df4049fda23110f1770a340a7bc2313b Mon Sep 17 00:00:00 2001 From: Chu'vok Date: Wed, 18 Sep 2024 12:41:57 +0200 Subject: [PATCH] fix -Wmissing-field-initializers --- tim.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tim.h b/tim.h index f4ec814..4250fab 100644 --- a/tim.h +++ b/tim.h @@ -1086,7 +1086,7 @@ static inline void label(const char* str, int x, int y, int w, int h, struct rect r = abs_xywh(x, y, w, h); struct cell c = cell(" ", color, color >> 8); draw_lot(c, r.x, r.y, r.w, r.h); - struct line l = {str}; + struct line l = {.str = str, .line = ""}; for (int i = 0; next_line(&l); i++) { draw_str(l.line, r.x, r.y + i, l.width, c.fg, c.bg); }