mirror of https://github.com/axmolengine/axmol.git
Merge pull request #6869 from visiblelight/texturecache
adding guard for the callback condition in `TextureCache::addImageAsyncCallBack`
This commit is contained in:
commit
45cce2a692
|
@ -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();
|
||||
|
|
Loading…
Reference in New Issue