mirror of
https://github.com/UberGames/ioef.git
synced 2024-11-28 06:52:35 +00:00
Fix this bug in a better way.
This commit is contained in:
parent
fdb66505bf
commit
b0a753eb0f
1 changed files with 9 additions and 8 deletions
|
@ -2327,14 +2327,15 @@ static char *FindShaderInShaderText( const char *shadername ) {
|
||||||
|
|
||||||
hash = generateHashValue(shadername, MAX_SHADERTEXT_HASH);
|
hash = generateHashValue(shadername, MAX_SHADERTEXT_HASH);
|
||||||
|
|
||||||
if(!shaderTextHashTable[hash])
|
if(shaderTextHashTable[hash])
|
||||||
return NULL;
|
{
|
||||||
|
for (i = 0; shaderTextHashTable[hash][i]; i++)
|
||||||
|
{
|
||||||
|
p = shaderTextHashTable[hash][i];
|
||||||
|
token = COM_ParseExt(&p, qtrue);
|
||||||
|
|
||||||
for (i = 0; shaderTextHashTable[hash][i]; i++) {
|
if(!Q_stricmp(token, shadername))
|
||||||
p = shaderTextHashTable[hash][i];
|
return p;
|
||||||
token = COM_ParseExt(&p, qtrue);
|
|
||||||
if ( !Q_stricmp( token, shadername ) ) {
|
|
||||||
return p;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue