summaryrefslogtreecommitdiff
path: root/src/game
diff options
context:
space:
mode:
Diffstat (limited to 'src/game')
-rw-r--r--src/game/g_client.c2
-rw-r--r--src/game/g_maprotation.c7
2 files changed, 3 insertions, 6 deletions
diff --git a/src/game/g_client.c b/src/game/g_client.c
index 3022a9cc..d0f9349f 100644
--- a/src/game/g_client.c
+++ b/src/game/g_client.c
@@ -887,7 +887,7 @@ static qboolean G_NonSegModel( const char *filename )
return qfalse;
}
- if( len <= 0 )
+ if( len < 0 )
return qfalse;
if( len >= sizeof( text ) - 1 )
diff --git a/src/game/g_maprotation.c b/src/game/g_maprotation.c
index b97b3b6f..b34370b8 100644
--- a/src/game/g_maprotation.c
+++ b/src/game/g_maprotation.c
@@ -310,7 +310,7 @@ static qboolean G_ParseMapRotationFile( const char *fileName )
// load the file
len = trap_FS_FOpenFile( fileName, &f, FS_READ );
- if( len <= 0 )
+ if( len < 0 )
return qfalse;
if( len >= sizeof( text ) - 1 )
@@ -773,13 +773,10 @@ Load and intialise the map rotations
void G_InitMapRotations( void )
{
const char *fileName = "maprotation.cfg";
- fileHandle_t f;
//load the file if it exists
- if( trap_FS_FOpenFile( fileName, &f, FS_READ ) > 0 )
+ if( trap_FS_FOpenFile( fileName, NULL, FS_READ ) )
{
- trap_FS_FCloseFile( f );
-
if( !G_ParseMapRotationFile( fileName ) )
G_Printf( S_COLOR_RED "ERROR: failed to parse %s file\n", fileName );
}