From 5f0829d7c0db5a4f9d008434e8e1bcd12ca59b9f Mon Sep 17 00:00:00 2001 From: Thierry Vignaud Date: Sat, 1 Dec 2018 14:03:24 +0100 Subject: better gcc8 workarounds --- mdk-stage1/thirdparty.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'mdk-stage1/thirdparty.c') diff --git a/mdk-stage1/thirdparty.c b/mdk-stage1/thirdparty.c index 9a9e58e39..78bbf485a 100644 --- a/mdk-stage1/thirdparty.c +++ b/mdk-stage1/thirdparty.c @@ -241,10 +241,10 @@ static int pcitable_orderer(const void *a, const void *b) static void thirdparty_load_pcitable(const char *modules_location) { - char pcitable_filename[110]; + char pcitable_filename[100]; FILE * f = NULL; - sprintf(pcitable_filename, "%s/pcitable", modules_location); + snprintf(pcitable_filename, sizeof(pcitable_filename), "%s/pcitable", modules_location); if (!(f = fopen(pcitable_filename, "rb"))) { log_message("third_party: no external pcitable found"); return; @@ -346,7 +346,7 @@ static enum return_type thirdparty_autoload_modules(const char *modules_location static enum return_type thirdparty_try_directory(char * root_directory, int interactive) { char modules_location[100]; - char modules_location_release[200]; + char modules_location_release[100]; char *list_filename; FILE *f_load, *f_detect; char **modules_list, **modules_list_release; -- cgit v1.2.1