]> git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - model_shared.c
Add another bug entry
[xonotic/darkplaces.git] / model_shared.c
index 6fd2527365adb903ff7a3ed3d155c316dd23d353..c1bd882ffad173d045c68434a171fb42d35bd5a2 100644 (file)
@@ -1578,7 +1578,7 @@ static void Q3Shader_AddToHash (q3shaderinfo_t* shader)
        unsigned short hash = CRC_Block_CaseInsensitive ((const unsigned char *)shader->name, strlen (shader->name));
        q3shader_hash_entry_t* entry = q3shader_data->hash + (hash % Q3SHADER_HASH_SIZE);
        q3shader_hash_entry_t* lastEntry = NULL;
-       while (entry != NULL)
+       do
        {
                if (strcasecmp (entry->shader.name, shader->name) == 0)
                {
@@ -1611,6 +1611,7 @@ static void Q3Shader_AddToHash (q3shaderinfo_t* shader)
                lastEntry = entry;
                entry = entry->chain;
        }
+       while (entry != NULL);
        if (entry == NULL)
        {
                if (lastEntry->shader.name[0] != 0)
@@ -2747,9 +2748,6 @@ nothing                GL_ZERO GL_ONE
                                {
                                        if(texture->skinframes[0]->hasalpha)
                                                texture->basematerialflags |= MATERIALFLAG_ALPHA | MATERIALFLAG_BLENDED | MATERIALFLAG_NOSHADOW;
-                                       texture->q2flags = texture->skinframes[0]->q2flags;
-                                       texture->q2value = texture->skinframes[0]->q2value;
-                                       texture->q2contents = texture->skinframes[0]->q2contents;
                                        if (texture->q2contents)
                                                texture->supercontents = Mod_Q2BSP_SuperContentsFromNativeContents(loadmodel, texture->q2contents);
                                }