From ac9759c082ceddd9818359eb33ccbbc6c7841676 Mon Sep 17 00:00:00 2001 From: Marvin Borner Date: Sat, 21 Nov 2020 22:37:27 +0100 Subject: Well, that's a strange fix This GUI bug actually caused DNS issues - LOL! --- libgui/gui.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libgui/gui.c b/libgui/gui.c index c3369bb..50c81c5 100644 --- a/libgui/gui.c +++ b/libgui/gui.c @@ -409,7 +409,8 @@ void gui_event_loop(struct element *container) event->scancode == KEY_ENTER) { focused->event.on_submit(event, focused); // Clear! - ((struct element_text_input *)focused->data)->text[0] = '\0'; + char *t = ((struct element_text_input *)focused->data)->text; + memset(t, 0, strlen(t)); gui_sync_text_input(focused); merge_elements(get_root(focused->window_id)); gfx_redraw_focused(); -- cgit v1.2.3