在iOS9.0之前,通知中心对观察者对象进行unsafe_unretained 引用,当被引用的对象释放时不会自动置为nil,,也就是成了野指针。

iOS9.0之后通知中心对观察者做了弱引用。

参考:https://blog.csdn.net/sinat_28585351/article/details/78133756



相关文章:

  • 2021-09-10
  • 2021-04-12
  • 2021-09-11
  • 2021-09-11
  • 2021-10-28
  • 2021-12-12
  • 2022-12-23
  • 2021-08-30
猜你喜欢
  • 2021-09-11
  • 2022-02-22
  • 2022-12-23
  • 2021-07-18
  • 2021-06-22
  • 2022-12-23
  • 2021-05-05
相关资源
相似解决方案