From 6cb0e9667deb34fabcb0f76b5a0843e898c4093b Mon Sep 17 00:00:00 2001 From: James R Date: Sat, 27 Feb 2021 03:09:45 -0800 Subject: [PATCH] Conflicts da7e79ac83 d5688f53a0 --- src/d_main.c | 2 +- src/w_wad.c | 9 ++++++++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/src/d_main.c b/src/d_main.c index 0b65ee0ee..597e3a3da 100644 --- a/src/d_main.c +++ b/src/d_main.c @@ -1070,7 +1070,7 @@ static void IdentifyVersion(void) #define MUSICTEST(str) \ {\ const char *musicpath = va(pandf,srb2waddir,str);\ - int ms = W_VerifyNMUSlumps(musicpath); \ + int ms = W_VerifyNMUSlumps(musicpath, false); \ if (ms == 1) \ D_AddFile(startupiwads, musicpath); \ else if (ms == 0) \ diff --git a/src/w_wad.c b/src/w_wad.c index 3bef13a12..5396b1bed 100644 --- a/src/w_wad.c +++ b/src/w_wad.c @@ -747,7 +747,14 @@ UINT16 W_InitFile(const char *filename, boolean mainfile, boolean startup) if ((handle = W_OpenWadFile(&filename, true)) == NULL) return W_InitFileError(filename, startup); - important = !W_VerifyNMUSlumps(filename); + important = W_VerifyNMUSlumps(filename, startup); + + if (important == -1) + { + fclose(handle); + return INT16_MAX; + } + #ifndef NOMD5 //