From aede680cd79a0609221742d06a198960ff9b21e2 Mon Sep 17 00:00:00 2001 From: Brad Parker Date: Fri, 16 Dec 2016 21:17:04 -0500 Subject: [PATCH] no need to zero the entire string --- ui/drivers/ui_win32.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/ui/drivers/ui_win32.c b/ui/drivers/ui_win32.c index 424dd0dbe2..204361f5b8 100644 --- a/ui/drivers/ui_win32.c +++ b/ui/drivers/ui_win32.c @@ -524,8 +524,11 @@ static bool win32_browser( /* These need to be big enough to hold the path/name of any file the user may select. * FIXME: We should really handle the error case when this isn't big enough. */ - char new_title[TITLE_MAX] = {0}; - char new_file[FULLPATH_MAX] = {0}; + char new_title[TITLE_MAX]; + char new_file[FULLPATH_MAX]; + + new_title[0] = '\0'; + new_file[0] = '\0'; if (title && *title) strlcpy(new_title, title, sizeof(new_title));