mirror of https://github.com/axmolengine/axmol.git
corrected bug and leak in getBool
This commit is contained in:
parent
af61a7c650
commit
41bdb281dc
|
@ -155,10 +155,8 @@ bool CCUserDefault::getBoolForKey(const char* pKey, bool defaultValue)
|
||||||
|
|
||||||
if (value)
|
if (value)
|
||||||
{
|
{
|
||||||
if (! strcmp(value, "true"))
|
ret = (! strcmp(value, "true"));
|
||||||
{
|
xmlFree((void*)value);
|
||||||
ret = true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
|
|
Loading…
Reference in New Issue