How do I debug this error: CFNOTIFICATIONCENTER_IS_CALLING_OUT_TO_AN_OBSERVER?

后端 未结 2 750
眼角桃花
眼角桃花 2021-02-04 09:38

I am getting an error in my app that I have no idea of how to figure out, has anyone seen this before:

#   Binary Image Name   Address Symbol
0   RepZio  0x002bd         


        
相关标签:
2条回答
  • 2021-02-04 10:09

    Make sure you remove all notification observers before freeing them. This problem occurs when an observer is freed and notification center has still a pointer to that object and tries to notify it. Check that all addObserver have the corresponding removeObserver calls.

    0 讨论(0)
  • 2021-02-04 10:18

    I know it's old question, but maybe I will help to someone.

    In my case the same crash occurred when NSTextField in NSTableViewCell was in editing mode and user tried to select value from combobox outside of tableView without finishing editing. And the same CFNOTIFICATIONCENTER_... crash was on line [tableView reloadData].

    So, my way to resolve crash was to put [self.window makeFirstResponder:nil] before reloading the table.

    0 讨论(0)
提交回复
热议问题