My application overrides AppDelegate.menuWillOpen(). During startup of the application (in AppDelegate.applicationDidFinishLaunching) I attempt to install a privileged helper tool using SMAppService. On detecting that the tool needs to be allowed/installed I open the Login Items & Extensions settings and then display a modal dialog, advising the user to authorise the privileged helper. Then the application crashes with a message in the crash file
Application Specific Information: BUG IN CLIENT OF LIBDISPATCH: trying to lock recursively
Maybe I could avoid this by removing the menuWillOpen() override so am looking for a workaround. i.e. is it possible to install the override function programmatically later during initialisation, rather then declaring it in an extension.
I have attached the crash log.