Search code examples
concurrencynsnotificationcenterfoundation

Is NSNotificationCenter thread safe?


Can I post a notification in a given queue and receive it on another? I want to use notifications to communicate different queues, but I'm not sure if this is safe...


Solution

  • No. Notifications are delivered in the same thread that they are sent from, this you will need to re-send it in some way to get the notification to your thread.