Rename FS_SV_* to FS_BaseDir_*
This commit is contained in:
1 parent
cadc8ab017
commit
3b90b76d7f
9 files changed
+33
-33
No files matched your search
@@ -2468,7 +2468,7 @@ void Com_ReadCDKey( const char *filename ) {
|
||||
|
||||
Com_sprintf(fbuffer, sizeof(fbuffer), "%s/q3key", filename);
|
||||
|
||||
FS_SV_FOpenFileRead( fbuffer, &f );
|
||||
FS_BaseDir_FOpenFileRead( fbuffer, &f );
|
||||
if ( !f ) {
|
||||
Com_Memset( cl_cdkey, '\0', 17 );
|
||||
return;
|
||||
@@ -2498,7 +2498,7 @@ void Com_AppendCDKey( const char *filename ) {
|
||||
|
||||
Com_sprintf(fbuffer, sizeof(fbuffer), "%s/q3key", filename);
|
||||
|
||||
FS_SV_FOpenFileRead( fbuffer, &f );
|
||||
FS_BaseDir_FOpenFileRead( fbuffer, &f );
|
||||
if (!f) {
|
||||
Com_Memset( &cl_cdkey[16], '\0', 17 );
|
||||
return;
|
||||
@@ -2543,7 +2543,7 @@ static void Com_WriteCDKey( const char *filename, const char *ikey ) {
|
||||
#ifndef _WIN32
|
||||
savedumask = umask(0077);
|
||||
#endif
|
||||
f = FS_SV_FOpenFileWrite( fbuffer );
|
||||
f = FS_BaseDir_FOpenFileWrite( fbuffer );
|
||||
if ( !f ) {
|
||||
Com_Printf ("Couldn't write CD key to %s.\n", fbuffer );
|
||||
goto out;
|
||||
|
||||
+14
-14
@@ -662,12 +662,12 @@ qboolean FS_FileExists(const char *file)
|
||||
|
||||
/*
|
||||
================
|
||||
FS_SV_FileExists
|
||||
FS_BaseDir_FileExists
|
||||
|
||||
Tests if the file exists
|
||||
================
|
||||
*/
|
||||
qboolean FS_SV_FileExists( const char *file )
|
||||
qboolean FS_BaseDir_FileExists( const char *file )
|
||||
{
|
||||
return FS_FileInPathExists(FS_BaseDir_BuildOSPath(fs_homepath->string, file));
|
||||
}
|
||||
@@ -675,11 +675,11 @@ qboolean FS_SV_FileExists( const char *file )
|
||||
|
||||
/*
|
||||
===========
|
||||
FS_SV_FOpenFileWrite
|
||||
FS_BaseDir_FOpenFileWrite
|
||||
|
||||
===========
|
||||
*/
|
||||
fileHandle_t FS_SV_FOpenFileWrite( const char *filename ) {
|
||||
fileHandle_t FS_BaseDir_FOpenFileWrite( const char *filename ) {
|
||||
char *ospath;
|
||||
fileHandle_t f;
|
||||
|
||||
@@ -693,7 +693,7 @@ fileHandle_t FS_SV_FOpenFileWrite( const char *filename ) {
|
||||
fsh[f].zipFile = qfalse;
|
||||
|
||||
if ( fs_debug->integer ) {
|
||||
Com_Printf( "FS_SV_FOpenFileWrite: %s\n", ospath );
|
||||
Com_Printf( "FS_BaseDir_FOpenFileWrite: %s\n", ospath );
|
||||
}
|
||||
|
||||
FS_CheckFilenameIsMutable( ospath, __func__ );
|
||||
@@ -716,13 +716,13 @@ fileHandle_t FS_SV_FOpenFileWrite( const char *filename ) {
|
||||
|
||||
/*
|
||||
===========
|
||||
FS_SV_FOpenFileRead
|
||||
FS_BaseDir_FOpenFileRead
|
||||
|
||||
Search for a file somewhere below the home path then base path
|
||||
in that order
|
||||
===========
|
||||
*/
|
||||
long FS_SV_FOpenFileRead(const char *filename, fileHandle_t *fp)
|
||||
long FS_BaseDir_FOpenFileRead(const char *filename, fileHandle_t *fp)
|
||||
{
|
||||
char *ospath;
|
||||
fileHandle_t f = 0;
|
||||
@@ -756,7 +756,7 @@ long FS_SV_FOpenFileRead(const char *filename, fileHandle_t *fp)
|
||||
|
||||
if ( fs_debug->integer )
|
||||
{
|
||||
Com_Printf( "FS_SV_FOpenFileRead (%s): %s\n", pathVar->name, ospath );
|
||||
Com_Printf( "FS_BaseDir_FOpenFileRead (%s): %s\n", pathVar->name, ospath );
|
||||
}
|
||||
|
||||
fsh[f].handleFiles.file.o = Sys_FOpen( ospath, "rb" );
|
||||
@@ -779,11 +779,11 @@ long FS_SV_FOpenFileRead(const char *filename, fileHandle_t *fp)
|
||||
|
||||
/*
|
||||
===========
|
||||
FS_SV_Rename
|
||||
FS_BaseDir_Rename
|
||||
|
||||
===========
|
||||
*/
|
||||
void FS_SV_Rename( const char *from, const char *to, qboolean safe ) {
|
||||
void FS_BaseDir_Rename( const char *from, const char *to, qboolean safe ) {
|
||||
char *from_ospath, *to_ospath;
|
||||
|
||||
if ( !fs_searchpaths ) {
|
||||
@@ -797,7 +797,7 @@ void FS_SV_Rename( const char *from, const char *to, qboolean safe ) {
|
||||
to_ospath = FS_BaseDir_BuildOSPath( fs_homepath->string, to );
|
||||
|
||||
if ( fs_debug->integer ) {
|
||||
Com_Printf( "FS_SV_Rename: %s --> %s\n", from_ospath, to_ospath );
|
||||
Com_Printf( "FS_BaseDir_Rename: %s --> %s\n", from_ospath, to_ospath );
|
||||
}
|
||||
|
||||
if ( safe ) {
|
||||
@@ -2480,7 +2480,7 @@ void FS_GetModDescription( const char *modDir, char *description, int descriptio
|
||||
FILE *file;
|
||||
|
||||
Com_sprintf( descPath, sizeof ( descPath ), "%s%cdescription.txt", modDir, PATH_SEP );
|
||||
nDescLen = FS_SV_FOpenFileRead( descPath, &descHandle );
|
||||
nDescLen = FS_BaseDir_FOpenFileRead( descPath, &descHandle );
|
||||
|
||||
if ( nDescLen > 0 ) {
|
||||
file = FS_FileForHandle(descHandle);
|
||||
@@ -3189,7 +3189,7 @@ qboolean FS_ComparePaks( char *neededpaks, int len, qboolean dlstring ) {
|
||||
// Local name
|
||||
Q_strcat( neededpaks, len, "@");
|
||||
// Do we have one with the same name?
|
||||
if ( FS_SV_FileExists( va( "%s.pk3", fs_serverReferencedPakNames[i] ) ) )
|
||||
if ( FS_BaseDir_FileExists( va( "%s.pk3", fs_serverReferencedPakNames[i] ) ) )
|
||||
{
|
||||
char st[MAX_ZPATH];
|
||||
// We already have one called this, we need to download it to another name
|
||||
@@ -3216,7 +3216,7 @@ qboolean FS_ComparePaks( char *neededpaks, int len, qboolean dlstring ) {
|
||||
Q_strcat( neededpaks, len, fs_serverReferencedPakNames[i] );
|
||||
Q_strcat( neededpaks, len, ".pk3" );
|
||||
// Do we have one with the same name?
|
||||
if ( FS_SV_FileExists( va( "%s.pk3", fs_serverReferencedPakNames[i] ) ) )
|
||||
if ( FS_BaseDir_FileExists( va( "%s.pk3", fs_serverReferencedPakNames[i] ) ) )
|
||||
{
|
||||
Q_strcat( neededpaks, len, " (local file exists with wrong checksum)");
|
||||
}
|
||||
|
||||
+1
-1
@@ -271,7 +271,7 @@ char *Com_MD5File( const char *fn, int length, const char *prefix, int prefix_le
|
||||
|
||||
Q_strncpyz( final, "", sizeof( final ) );
|
||||
|
||||
filelen = FS_SV_FOpenFileRead( fn, &f );
|
||||
filelen = FS_BaseDir_FOpenFileRead( fn, &f );
|
||||
|
||||
if( !f ) {
|
||||
return final;
|
||||
|
||||
@@ -645,9 +645,9 @@ fileHandle_t FS_FOpenFileAppend( const char *filename );
|
||||
fileHandle_t FS_FCreateOpenPipeFile( const char *filename );
|
||||
// will properly create any needed paths and deal with seperater character issues
|
||||
|
||||
fileHandle_t FS_SV_FOpenFileWrite( const char *filename );
|
||||
long FS_SV_FOpenFileRead( const char *filename, fileHandle_t *fp );
|
||||
void FS_SV_Rename( const char *from, const char *to, qboolean safe );
|
||||
fileHandle_t FS_BaseDir_FOpenFileWrite( const char *filename );
|
||||
long FS_BaseDir_FOpenFileRead( const char *filename, fileHandle_t *fp );
|
||||
void FS_BaseDir_Rename( const char *from, const char *to, qboolean safe );
|
||||
long FS_FOpenFileRead( const char *qpath, fileHandle_t *file, qboolean uniqueFILE );
|
||||
// if uniqueFILE is true, then a new FILE will be fopened even if the file
|
||||
// is found in an already open pak file. If uniqueFILE is false, you must call
|
||||
|
||||
Reference in new issue
Block a user