From d04f7e07d4a5278e8e8530925e2852b591d6e37b Mon Sep 17 00:00:00 2001 From: Zach DeCook Date: Sat, 22 Jan 2022 04:50:55 -0500 Subject: input: fix obvious memory leak --- keyboard.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'keyboard.c') diff --git a/keyboard.c b/keyboard.c index bfebdbe..1cc50da 100644 --- a/keyboard.c +++ b/keyboard.c @@ -15,9 +15,9 @@ void kbd_init(struct kbd *kb) { fprintf(stderr, "Initializing keyboard\n"); - kb->suggs[0].label = "Hello"; - kb->suggs[1].label = "World"; - kb->suggs[2].label = "World"; + kb->suggs[0].label = strdup("Hello"); + kb->suggs[1].label = strdup("Sugar"); + kb->suggs[2].label = strdup("Pie"); kb->suggs[3].label = NULL; } -- cgit 1.4.1