Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Transfer ownership of returned CF objects to avoid memory leak #196

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

wxxion
Copy link

@wxxion wxxion commented Jan 25, 2023

According to Apple doc, it's the responsibility of caller of SecAccessControlCreateWithFlags and SecItemCopyMatching to release the returned CF object. So we should __bridge_transfer the ownership to corresponding Objective-C object to manage the memory with ARC.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant