diff --git a/Makefile b/Makefile
index 2813eca..46822b1 100644
--- a/Makefile
+++ b/Makefile
@@ -1,7 +1,7 @@
# makefile to fail if any command in pipe is failed.
SHELL = /bin/bash -o pipefail
-# using gcc version 5.4.1 20161213 (Linaro GCC 5.4-2017.01-rc2)
+# using gcc version 7.5.0 (Linaro GCC 7.5-2019.12)
BASE = arm-linux-gnueabihf
CC = $(BASE)-gcc
@@ -46,7 +46,7 @@ OBJ = $(C_SRC:.c=.c.o) $(CPP_SRC:.cpp=.cpp.o) $(IMG:.png=.png.o)
DEP = $(C_SRC:.c=.c.d) $(CPP_SRC:.cpp=.cpp.d)
DFLAGS = $(INCLUDE) -D_7ZIP_ST -DPACKAGE_VERSION=\"1.3.3\" -DFLAC_API_EXPORTS -DFLAC__HAS_OGG=0 -DHAVE_LROUND -DHAVE_STDINT_H -DHAVE_STDLIB_H -DHAVE_SYS_PARAM_H -DENABLE_64_BIT_WORDS=0 -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -DVDATE=\"`date +"%y%m%d"`\"
-CFLAGS = $(DFLAGS) -Wall -Wextra -Wno-strict-aliasing -c -O3
+CFLAGS = $(DFLAGS) -Wall -Wextra -Wno-strict-aliasing -Wno-format-truncation -Wno-psabi -c -O3
LFLAGS = -lc -lstdc++ -lm -lrt $(IMLIB2_LIB)
$(PRJ): $(OBJ)
diff --git a/MiSTer.vcxproj b/MiSTer.vcxproj
index 01f275a..e7857cf 100644
--- a/MiSTer.vcxproj
+++ b/MiSTer.vcxproj
@@ -30,7 +30,7 @@
MiSTer
git.lnk ./clean.sh
__arm__;__GNUC__;__USE_GNU ;_GNU_SOURCE;VDATE="000000";_FILE_OFFSET_BITS=64;_LARGEFILE64_SOURCE;$(NMakePreprocessorDefinitions)
- c:\Work\Git\opt\gcc54\arm-linux-gnueabihf\libc\usr\include;c:\Work\Git\opt\gcc54\lib\gcc\arm-linux-gnueabihf\5.4.1\include;c:\Work\Git\opt\gcc54\arm-linux-gnueabihf\include\c++\5.4.1;c:\Work\Git\opt\gcc54\arm-linux-gnueabihf\include\c++\5.4.1\arm-linux-gnueabihf;$(NMakeIncludeSearchPath);lib\libco;lib\miniz;lib\lodepng
+ c:\Work\Git\opt\gcc75\arm-linux-gnueabihf\libc\usr\include;c:\Work\Git\opt\gcc75\lib\gcc\arm-linux-gnueabihf\7.5.0\include;c:\Work\Git\opt\gcc75\arm-linux-gnueabihf\include\c++\7.5.0;c:\Work\Git\opt\gcc75\arm-linux-gnueabihf\include\c++\7.5.0\arm-linux-gnueabihf;$(NMakeIncludeSearchPath);lib\libco;lib\miniz;lib\lodepng
$(TEMP)
$(TEMP)
diff --git a/lib/flac/src/include/share/alloc.h b/lib/flac/src/include/share/alloc.h
index 914de9b..ff93945 100644
--- a/lib/flac/src/include/share/alloc.h
+++ b/lib/flac/src/include/share/alloc.h
@@ -78,7 +78,7 @@ static inline void *safe_calloc_(size_t nmemb, size_t size)
{
if(!nmemb || !size)
return malloc(1); /* malloc(0) is undefined; FLAC src convention is to always allocate */
- return calloc(nmemb, size);
+ return (nmemb <= INT_MAX) ? calloc(nmemb, size) : NULL;
}
/*@@@@ there's probably a better way to prevent overflows when allocating untrusted sums but this works for now */
diff --git a/lib/libchdr/libchdr_chd.c b/lib/libchdr/libchdr_chd.c
index a3991e0..416769b 100644
--- a/lib/libchdr/libchdr_chd.c
+++ b/lib/libchdr/libchdr_chd.c
@@ -1272,6 +1272,8 @@ static chd_error decompress_v5_map(chd_file* chd, chd_header* header)
/* pseudo-types; convert into base types */
case COMPRESSION_SELF_1:
last_self++;
+ // fall through
+
case COMPRESSION_SELF_0:
rawmap[0] = COMPRESSION_SELF;
offset = last_self;
@@ -1284,6 +1286,8 @@ static chd_error decompress_v5_map(chd_file* chd, chd_header* header)
case COMPRESSION_PARENT_1:
last_parent += header->hunkbytes / header->unitbytes;
+ // fall through
+
case COMPRESSION_PARENT_0:
rawmap[0] = COMPRESSION_PARENT;
offset = last_parent;
diff --git a/menu.cpp b/menu.cpp
index 7d0c687..1cd2109 100644
--- a/menu.cpp
+++ b/menu.cpp
@@ -5525,6 +5525,7 @@ void HandleUI(void)
while(m < OsdGetSize()-1) OsdWrite(m++, "");
OsdWrite(15, STD_EXIT, menusub == 5);
menustate = MENU_SYSTEM2;
+ break;
case MENU_SYSTEM2:
if (menu)
diff --git a/support/arcade/mra_loader.cpp b/support/arcade/mra_loader.cpp
index a2420a1..b224ba1 100644
--- a/support/arcade/mra_loader.cpp
+++ b/support/arcade/mra_loader.cpp
@@ -728,13 +728,13 @@ static int xml_send_rom(XMLEvent evt, const XMLNode* node, SXML_CHAR* text, cons
* the buffer_append is part of a buffer library that will realloc automatically
*/
{
- int result = buffer_append(arc_info->data, text);
- if (result<0)
- printf("buffer_append failed %d\n",result);
+ int result = buffer_append(arc_info->data, text);
+ if (result<0)
+ printf("buffer_append failed %d\n",result);
if (result==-1)
- printf("-1 no data given\n");
+ printf("-1 no data given\n");
if (result==-2)
- printf("-2 could not allocate\n");
+ printf("-2 could not allocate\n");
}
//printf("XML_EVENT_TEXT: text [%s]\n",text);
break;