Merge pull request #6869 from visiblelight/texturecache

adding guard for the callback condition in `TextureCache::addImageAsyncCallBack`
This commit is contained in:
James Chen 2014-05-22 00:38:00 -05:00
commit 45cce2a692
1 changed files with 5 additions and 1 deletions

View File

@ -268,7 +268,11 @@ void TextureCache::addImageAsyncCallBack(float dt)
texture = it->second;
}
asyncStruct->callback(texture);
if (asyncStruct->callback)
{
asyncStruct->callback(texture);
}
if(image)
{
image->release();