Skip to content

关于野指针crash的防治上问题讨论 #33

@erduoniba

Description

@erduoniba

思路是非常好,但是在实际中,有不少问题,反而导致crash涨了非常多。
1、如果hook系统的dealloc,会调用非常多次xx_danglingPointer_dealloc,导致系统其他异常crash,而且不少;
2、如果根据类,然后进行hook其dealloc方法,不要hook一些UIView的dealloc,会出现DanglingPointStub or one of its superclasses may have overridden -updateViewConstraints without calling super or sending -updateConstraints to the view. Or, something may have dirtied layout constraints in the middle of updating them. Both are programming errors.的crash

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions