From cd98111312dad060bed8a1e4e122cf58dcad7dc4 Mon Sep 17 00:00:00 2001 From: knoxHuang <821686174@qq.com> Date: Wed, 30 Nov 2016 14:18:26 +0800 Subject: [PATCH] Fixed a dead loop when the file texture uuid is undefined for fireball/issues/4822 --- cocos2d/particle/CCParticleSystem.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/cocos2d/particle/CCParticleSystem.js b/cocos2d/particle/CCParticleSystem.js index 86c88cff68..18a77a61fd 100644 --- a/cocos2d/particle/CCParticleSystem.js +++ b/cocos2d/particle/CCParticleSystem.js @@ -918,6 +918,10 @@ var ParticleSystem = cc.Class({ // so use the texutreUuid instead of textureImageData if (content.textureUuid) { cc.AssetLibrary.queryAssetInfo(content.textureUuid, function (err, url, raw) { + if (err) { + cc.error(err); + return; + } self.texture = url; }); }