osx - Should i release objects that i get from dictionary on Mac? -


ie:

boolref = (cfbooleanref)cfdictionarygetvalue(descriptiondictionary, kdadiskdescriptionmediaremovablekey); if (boolref) {     cfrelease(boolref); // need code? } 

first read memory management programming guide core foundation. answer no, because of create rule. cfdictionarygetvalue() not include words "create" or "copy."

note cfrelease() in case not unneeded, incorrect , lead over-release crash.


Comments

Popular posts from this blog

SAP Web Service from .NET via WCF -

Optimized Line drawing in QT -

datetime - str to time in python -