mirror of
https://github.com/darlinghq/darling-corefoundation.git
synced 2024-11-26 21:30:22 +00:00
Support CFRelease() on TFBed objects even without Foundation
See https://github.com/darlinghq/darling-security/pull/3
This commit is contained in:
parent
4809c095d9
commit
2cbfb0348f
@ -1697,7 +1697,11 @@ static void _CFRelease(CFTypeRef cf) {
|
||||
}
|
||||
|
||||
{
|
||||
Boolean isValidObjCObject = ((CFRuntimeBase *) cf)->_cfisa != 0;
|
||||
Boolean isValidObjCObject = false;
|
||||
if (((CFRuntimeBase *) cf)->_cfisa) {
|
||||
Class class = object_getClass(cf);
|
||||
isValidObjCObject = !_class_isFutureClass(class);
|
||||
}
|
||||
if (isValidObjCObject) {
|
||||
if (__CFZombieEnabled) {
|
||||
[(id)cf dealloc];
|
||||
|
Loading…
Reference in New Issue
Block a user