Hi, I have a cocoa app which is cancelling shutdown (message in german is "das Programm hat das Beenden abgebrochen"), and I don't know why. It also only happens sometimes. I am trying to shutdown with the applescript "tell application "System Events" to shut down", and I can't figure out what is causing the shutdown to cancel.
The app delegate's applicationShouldTerminate: is apparently not being called, so its not that. My app delegate doesn't define anything else besides applicationDidFinishLaunching: , so it doesn't seem to be the delegate. I have a couple ideas but neither has suggested a possible fix: First is that app in question is a cocoa app that previously was a command line app, and so it is *not* calling NSApplicationMain. It starts its own run loop. Although I'm calling CFRunLoopRunInMode in the loop, could there be some other something that I need to do in the run loop that would potentially cause a shutdown to cancel? Before when this was a command line tool, this shutdown problem never occurred. Second is that this app is being launched programmatically from another app, using [NSTask launchedTaskWithLaunchPath:arguments:]. If I launch the app directly, it does not seem to impede shutdown. Is there somehow a way for a retained subprocess to cause a shutdown to abort? Thanks for any insight, Elizabeth _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com