• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Uncaught exceptions not terminating my app
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Uncaught exceptions not terminating my app


  • Subject: Uncaught exceptions not terminating my app
  • From: "Paul Sanders" <email@hidden>
  • Date: Wed, 20 Jan 2010 19:27:20 -0000

Greetings all,

I am experiencing a strange problem with the handling of uncaught exceptions which I'm hoping someone can shed some light on.

This document:

http://developer.apple.com/mac/library/DOCUMENTATION/Cocoa/Conceptual/Exceptions/Tasks/ControllingAppResponse.html#//apple_ref/doc/uid/20000473

states that certain classes of exception will terminate the app if they are not caught.  But this is not the behaviour I observe.  To take a specific example, executing this code:

    [NSObject noSuchSelector];
    foo ();

Just abruptly returns to the main event loop (and the call to foo (), and whatever follows, is never executed).  This is _not_ the behaviour I want.  If I am stupid enough to send a message to an object that doesn't recognise it, I'd like my program to crash (and therefore generate a crash log).  Then, when it restarts, it offers to send the log to me (thank you, Uli M Kusterer).  Otherwise, my app will just behave strangely and I will never even know I have a bug.  Exit one [potential] customer.

This is all happening on 10.5.8, but 10.6.2 seems to be the same.  Any insight greatly appreciated.  Thanks.

Paul Sanders.
_______________________________________________

Cocoa-dev mailing list (email@hidden)

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:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Uncaught exceptions not terminating my app
      • From: Ken Thomases <email@hidden>
  • Prev by Date: Re: Socket Blocking Question
  • Next by Date: Re: Socket Blocking Question
  • Previous by thread: Presets & NSPrintPanel accessory view
  • Next by thread: Re: Uncaught exceptions not terminating my app
  • Index(es):
    • Date
    • Thread