- fixed: bucket in FTextureManager::AddTexture should be a signed int.

SVN r1301 (trunk)
This commit is contained in:
Christoph Oelckers 2008-11-30 13:42:30 +00:00
parent 3f2d5db348
commit c3906850f7
2 changed files with 2 additions and 3 deletions

View file

@ -297,7 +297,7 @@ void FTextureManager::UnloadAll ()
FTextureID FTextureManager::AddTexture (FTexture *texture)
{
size_t bucket;
int bucket;
int hash;
if (texture == NULL) return FTextureID(-1);
@ -307,7 +307,7 @@ FTextureID FTextureManager::AddTexture (FTexture *texture)
// Textures without name can't be looked for
if (texture->Name[0] != 0)
{
bucket = MakeKey (texture->Name) % HASH_SIZE;
bucket = int(MakeKey (texture->Name) % HASH_SIZE);
hash = HashFirst[bucket];
}
else

View file

@ -300,7 +300,6 @@ public:
void LoadTextureDefs(int wadnum, const char *lumpname);
void ParseXTexture(FScanner &sc, int usetype);
void SortTexturesByType(int start, int end);
void RemoveTexture();
FTextureID CreateTexture (int lumpnum, int usetype=FTexture::TEX_Any); // Also calls AddTexture
FTextureID AddTexture (FTexture *texture);