Re: Beware: trivially reproducible NSPersistentDocument crash when saving
Re: Beware: trivially reproducible NSPersistentDocument crash when saving
- Subject: Re: Beware: trivially reproducible NSPersistentDocument crash when saving
- From: "Sean McBride" <email@hidden>
- Date: Tue, 25 Aug 2009 17:52:29 -0400
- Organization: Rogue Research Inc.
On 8/25/09 2:44 PM, Kyle Sluder said:
>> Let's say you have an NSPersistentDocument-based app-- you do some work
>> and you save successfully. Now let's say the app has a bug where its UI
>> allows the user to set a value outside the allowable range of one of
>> your NSManagedObjects. When you try to save, the OS will give a
>message like:
>
>Do you mean when you try to stuff a 16-bit variable into an 8-bit
>integer field? Or does it happen even when the value is representable
>but just outside the allowable range?
Let's say you have an attribute that is an int32, but you set its 'min
value' to 0. Then you bind this to an NSSlider that goes from -100 to
100. Then you slide the slider to the -100 value. At save time, the OS
complains that -100 is 'too small'. That's all fine, the problem comes
later when you try 'save a's then 'save' again. Then it crashes instead
of displaying the error.
--
____________________________________________________________
Sean McBride, B. Eng email@hidden
Rogue Research www.rogue-research.com
Mac Software Developer Montréal, Québec, Canada
_______________________________________________
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