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

modify the KVO function #36

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open

modify the KVO function #36

wants to merge 5 commits into from

Conversation

dourgulf
Copy link

The original KVO use runtime to hook UITextView’s dealloc method and
release. This method maybe cause a problem: When this category was
compile into a dynamic framework, and was used in other project which
also reference this category. In that case, the runtime hook two times,
and result is KVO not removed. This case can be reproduce in demo project: compile “UITextView+Placeholder.m” file in demo project and framework both.

The original KVO use runtime to hook UITextView’s dealloc method and
release. This method maybe cause a problem: When this category was
compile into a dynamic framework, and was used in other project which
also reference this category. In that case, the runtime hook two times,
and result is KVO not removed.
@devxoul
Copy link
Owner

devxoul commented Nov 12, 2016

@dourgulf, thanks for your work. I'll take a look this soon 👍

@dourgulf
Copy link
Author

nice, you are still focus on this project:)

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.

None yet

2 participants