Skip to content

Commit b06620b

Browse files
committed
fpersmissive fixes
1 parent 29db778 commit b06620b

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+220
-185
lines changed

bitmap/float_bm.cpp

Lines changed: 143 additions & 103 deletions
Large diffs are not rendered by default.

datacache/mdlcache.cpp

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1450,9 +1450,6 @@ virtualmodel_t *CMDLCache::GetVirtualModelFast( const studiohdr_t *pStudioHdr, M
14501450

14511451
AllocateVirtualModel( handle );
14521452

1453-
// MoeMod : added
1454-
pStudioHdr->SetVirtualModel( MDLHandleToVirtual( handle ) );
1455-
14561453
// Group has to be zero to ensure refcounting is correct
14571454
int nGroup = pStudioData->m_pVirtualModel->m_group.AddToTail( );
14581455
Assert( nGroup == 0 );

engine/baseclient.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1098,10 +1098,10 @@ void CBaseClient::EndTrace( bf_write &msg )
10981098
}
10991099

11001100
if ( sv_netspike_output.GetInt() & 1 )
1101-
COM_LogString( SERVER_PACKETS_LOG, logData.String() );
1101+
COM_LogString( SERVER_PACKETS_LOG, (const char*)logData.String() );
11021102
if ( sv_netspike_output.GetInt() & 2 )
1103-
Log( "%s", logData.String() );
1104-
ETWMark1S( "netspike", logData.String() );
1103+
Log( "%s", (const char*)logData.String() );
1104+
ETWMark1S( "netspike", (const char*)logData.String() );
11051105
m_Trace.m_Records.RemoveAll();
11061106
m_iTracing = 0;
11071107
}

engine/cmodel_disp.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,7 @@ void CM_CreateDispPhysCollide( dphysdisp_t *pDispLump, int dispLumpSize )
318318
{
319319
g_VirtualTerrain.LevelInit(pDispLump, dispLumpSize);
320320
g_TerrainList.SetCount( g_DispCollTreeCount );
321-
for ( int i = 0; i < g_DispCollTreeCount; i++ )
321+
for ( intp i = 0; i < g_DispCollTreeCount; i++ )
322322
{
323323
// Don't create a physics collision model for displacements that have been tagged as such.
324324
CDispCollTree *pDispTree = &g_pDispCollTrees[i];

engine/dt_encode.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ void EncodeFloat( const SendProp *pProp, float fVal, bf_write *pOut, int objectI
3939
}
4040
else // standard clamped-range float
4141
{
42-
unsigned long ulVal;
42+
unsigned int ulVal;
4343
int nBits = pProp->m_nBits;
4444
if ( flags & SPROP_NOSCALE )
4545
{
@@ -109,7 +109,7 @@ static float DecodeFloat(SendProp const *pProp, bf_read *pIn)
109109
}
110110
else // standard clamped-range float
111111
{
112-
unsigned long dwInterp = pIn->ReadUBitLong(pProp->m_nBits);
112+
unsigned int dwInterp = pIn->ReadUBitLong(pProp->m_nBits);
113113
float fVal = (float)dwInterp / ((1 << pProp->m_nBits) - 1);
114114
fVal = pProp->m_fLowValue + (pProp->m_fHighValue - pProp->m_fLowValue) * fVal;
115115
return fVal;
@@ -281,7 +281,7 @@ void Int_Decode( DecodeInfo *pInfo )
281281
{
282282
if ( flags & SPROP_UNSIGNED )
283283
{
284-
pInfo->m_Value.m_Int = (long)pInfo->m_pIn->ReadVarInt32();
284+
pInfo->m_Value.m_Int = (int)pInfo->m_pIn->ReadVarInt32();
285285
}
286286
else
287287
{
@@ -295,7 +295,7 @@ void Int_Decode( DecodeInfo *pInfo )
295295

296296
if( bits != 32 && (flags & SPROP_UNSIGNED) == 0 )
297297
{
298-
unsigned long highbit = 1ul << (pProp->m_nBits - 1);
298+
unsigned int highbit = 1ul << (pProp->m_nBits - 1);
299299
if ( pInfo->m_Value.m_Int & highbit )
300300
{
301301
pInfo->m_Value.m_Int -= highbit; // strip high bit...

engine/saverestore_filesystem.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -310,12 +310,12 @@ int CSaveRestoreFileSystem::GetFileIndex( const char *filename )
310310

311311
FileHandle_t CSaveRestoreFileSystem::GetFileHandle( const char *filename )
312312
{
313-
int idx = GetFileIndex( filename );
313+
intp idx = GetFileIndex( filename );
314314
if ( idx == INVALID_INDEX )
315315
{
316316
idx = 0;
317317
}
318-
return (void*)idx;
318+
return (FileHandle_t)idx;
319319
}
320320

321321
//-----------------------------------------------------------------------------
@@ -339,7 +339,7 @@ bool CSaveRestoreFileSystem::HandleIsValid( FileHandle_t hFile )
339339
//-----------------------------------------------------------------------------
340340
void CSaveRestoreFileSystem::RenameFile( char const *pOldPath, char const *pNewPath, const char *pathID )
341341
{
342-
int idx = GetFileIndex( pOldPath );
342+
intp idx = GetFileIndex( pOldPath );
343343
if ( idx != INVALID_INDEX )
344344
{
345345
CUtlSymbol newID = AddString( Q_UnqualifiedFileName( pNewPath ) );
@@ -369,7 +369,7 @@ FileHandle_t CSaveRestoreFileSystem::Open( const char *pFullName, const char *pO
369369
{
370370
SaveFile_t *pFile = NULL;
371371
CUtlSymbol id = AddString( Q_UnqualifiedFileName( pFullName ) );
372-
int idx = GetDirectory().Find( id );
372+
intp idx = GetDirectory().Find( id );
373373
if ( idx == INVALID_INDEX )
374374
{
375375
// Don't create a read-only file

engine/sv_main.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@
7575

7676
// memdbgon must be the last include file in a .cpp file!!!
7777
#include "tier0/memdbgon.h"
78+
#include "tier0/memalloc.h"
7879

7980
extern CNetworkStringTableContainer *networkStringTableContainerServer;
8081
extern CNetworkStringTableContainer *networkStringTableContainerClient;

engine/sys_dll2.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,7 @@
100100

101101
// memdbgon must be the last include file in a .cpp file!!!
102102
#include "tier0/memdbgon.h"
103+
#include "tier0/memalloc.h"
103104

104105
//-----------------------------------------------------------------------------
105106
// Globals

filesystem/QueuedLoader.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -306,7 +306,7 @@ CQueuedLoader::CQueuedLoader() : BaseClass( false )
306306
V_memset( m_pLoaders, 0, sizeof( m_pLoaders ) );
307307

308308
// set resource dictionaries sort context
309-
for ( int i = 0; i < RESOURCEPRELOAD_COUNT; i++ )
309+
for ( intp i = 0; i < RESOURCEPRELOAD_COUNT; i++ )
310310
{
311311
m_ResourceNames[i].SetLessContext( (void *)i );
312312
}

filesystem/filesystem_async.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ class CAsyncOpenedFiles
126126

127127
AUTO_LOCK( m_mutex );
128128

129-
int iEntry = m_map.Find( szFixedName );
129+
intp iEntry = m_map.Find( szFixedName );
130130
if ( iEntry == m_map.InvalidIndex() )
131131
{
132132
iEntry = m_map.Insert( strdup( szFixedName ), new AsyncOpenedFile_t );
@@ -146,7 +146,7 @@ class CAsyncOpenedFiles
146146

147147
AUTO_LOCK( m_mutex );
148148

149-
int iEntry = m_map.Find( szFixedName );
149+
intp iEntry = m_map.Find( szFixedName );
150150
if ( iEntry != m_map.InvalidIndex() )
151151
{
152152
m_map[iEntry]->AddRef();

0 commit comments

Comments
 (0)