From f2cbe232dee089d8b74b7703c13e82a4a8f5a461 Mon Sep 17 00:00:00 2001 From: Bill Currie Date: Thu, 3 Jan 2002 22:12:23 +0000 Subject: [PATCH] correct a misleading error and some missed foundname sets --- qcommon/files.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/qcommon/files.c b/qcommon/files.c index c409395..2710cfc 100644 --- a/qcommon/files.c +++ b/qcommon/files.c @@ -282,6 +282,7 @@ int _FS_FOpenFile (char *filename, QFile **file, char *foundname, int zip) #endif if (*file) { + strncpy (foundname, netpath, MAX_OSPATH); Com_DPrintf ("link file: %s\n",netpath); return size; } @@ -314,7 +315,7 @@ int _FS_FOpenFile (char *filename, QFile **file, char *foundname, int zip) pak->files[i].filepos, pak->files[i].filelen, zip, &size); if (!*file) - Com_Error (ERR_FATAL, "Couldn't reopen %s", pak->filename); + Com_Error (ERR_FATAL, "Couldn't open %s", foundname); return size; } } @@ -334,6 +335,7 @@ int _FS_FOpenFile (char *filename, QFile **file, char *foundname, int zip) if (!*file) continue; + strncpy (foundname, netpath, MAX_OSPATH); Com_DPrintf ("FindFile: %s\n",netpath); return size;