From 60d1e221603cec403996bff02a1b47b8716b68f9 Mon Sep 17 00:00:00 2001 From: Tyrann Date: Mon, 2 Oct 2006 12:58:44 +0930 Subject: [PATCH] [PATCH] qbsp: Fix warning about invalid wads Add back the warning message about invalid wads. Don't bother to differentiate between filesystem errors and bad magic, etc. The file is already open, so if we can't read it's either too small or there might be some hardware problem (not worth dealing with separately). Signed-off-by: Tyrann --- qbsp/wad.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/qbsp/wad.c b/qbsp/wad.c index 72c598fa..af2a0090 100644 --- a/qbsp/wad.c +++ b/qbsp/wad.c @@ -85,10 +85,11 @@ WADList_Init(wadlist_t *list, char *wadstring) wadstring[i++] = 0; w->file = fopen(fname, "rb"); if (w->file) { - if (WAD_LoadInfo(w)) - w++; - else + if (!WAD_LoadInfo(w)) { + Message(msgWarning, warnNotWad, fname); fclose(w->file); + } else + w++; } }