comment out COM_DefaultExtension

git-svn-id: svn://svn.code.sf.net/p/quakespasm/code/trunk/quakespasm@905 af15c1b1-3010-417e-b628-4374ebc0bcbd
This commit is contained in:
Ozkan Sezer 2014-04-27 08:33:05 +00:00
parent d941ee83db
commit 5ad7885e70
3 changed files with 10 additions and 6 deletions

View File

@ -1,11 +1,11 @@
support for user directories, based on uhexen2 and tyrquake: support for user directories, based on uhexen2 and tyrquake:
** against quakespasm svn revision 904. ** against quakespasm svn revision 905.
** on-the-fly game directory switching not supported yet. ** on-the-fly game directory switching not supported yet.
** minimally tested, needs more work. ** minimally tested, needs more work.
Index: Quake/sys_sdl_unix.c Index: Quake/sys_sdl_unix.c
=================================================================== ===================================================================
--- Quake/sys_sdl_unix.c (revision 904) --- Quake/sys_sdl_unix.c (revision 905)
+++ Quake/sys_sdl_unix.c (working copy) +++ Quake/sys_sdl_unix.c (working copy)
@@ -20,6 +20,8 @@ @@ -20,6 +20,8 @@
@ -73,9 +73,9 @@ Index: Quake/sys_sdl_unix.c
void Sys_mkdir (const char *path) void Sys_mkdir (const char *path)
Index: Quake/common.c Index: Quake/common.c
=================================================================== ===================================================================
--- Quake/common.c (revision 904) --- Quake/common.c (revision 905)
+++ Quake/common.c (working copy) +++ Quake/common.c (working copy)
@@ -1917,6 +1917,7 @@ static void COM_AddGameDirectory (const @@ -1919,6 +1919,7 @@ static void COM_AddGameDirectory (const
searchpath_t *search; searchpath_t *search;
pack_t *pak, *qspak; pack_t *pak, *qspak;
char pakfile[MAX_OSPATH]; char pakfile[MAX_OSPATH];
@ -83,7 +83,7 @@ Index: Quake/common.c
q_strlcpy (com_gamedir, va("%s/%s", base, dir), sizeof(com_gamedir)); q_strlcpy (com_gamedir, va("%s/%s", base, dir), sizeof(com_gamedir));
@@ -1925,6 +1926,7 @@ static void COM_AddGameDirectory (const @@ -1927,6 +1928,7 @@ static void COM_AddGameDirectory (const
path_id = com_searchpaths->path_id << 1; path_id = com_searchpaths->path_id << 1;
else path_id = 1U; else path_id = 1U;
@ -91,7 +91,7 @@ Index: Quake/common.c
// add the directory to the search path // add the directory to the search path
search = (searchpath_t *) Z_Malloc(sizeof(searchpath_t)); search = (searchpath_t *) Z_Malloc(sizeof(searchpath_t));
search->path_id = path_id; search->path_id = path_id;
@@ -1961,6 +1963,14 @@ static void COM_AddGameDirectory (const @@ -1963,6 +1965,14 @@ static void COM_AddGameDirectory (const
} }
if (!pak) break; if (!pak) break;
} }

View File

@ -1056,6 +1056,7 @@ if path doesn't have a .EXT, append extension
(extension should include the leading ".") (extension should include the leading ".")
================== ==================
*/ */
#if 0 /* can be dangerous */
void COM_DefaultExtension (char *path, const char *extension, size_t len) void COM_DefaultExtension (char *path, const char *extension, size_t len)
{ {
char *src; char *src;
@ -1072,6 +1073,7 @@ void COM_DefaultExtension (char *path, const char *extension, size_t len)
q_strlcat(path, extension, len); q_strlcat(path, extension, len);
} }
#endif
/* /*
================== ==================

View File

@ -180,7 +180,9 @@ const char *COM_SkipPath (const char *pathname);
void COM_StripExtension (const char *in, char *out, size_t outsize); void COM_StripExtension (const char *in, char *out, size_t outsize);
void COM_FileBase (const char *in, char *out, size_t outsize); void COM_FileBase (const char *in, char *out, size_t outsize);
void COM_AddExtension (char *path, const char *extension, size_t len); void COM_AddExtension (char *path, const char *extension, size_t len);
#if 0 /* COM_DefaultExtension can be dangerous */
void COM_DefaultExtension (char *path, const char *extension, size_t len); void COM_DefaultExtension (char *path, const char *extension, size_t len);
#endif
const char *COM_FileGetExtension (const char *in); /* doesn't return NULL */ const char *COM_FileGetExtension (const char *in); /* doesn't return NULL */
void COM_ExtractExtension (const char *in, char *out, size_t outsize); void COM_ExtractExtension (const char *in, char *out, size_t outsize);
void COM_CreatePath (char *path); void COM_CreatePath (char *path);