URL:
<http://savannah.gnu.org/patch/?6286>
Summary: NSBezierPath encode/decode improperly implemented
Project: GNUstep
Submitted by: wojno
Submitted on: Tuesday 11/27/2007 at 06:43
Category: AppKit
Priority: 7 - High
Status: None
Privacy: Public
Assigned to: None
Originator Email:
Open/Closed: Open
Discussion Lock: Any
_______________________________________________________
Details:
NSBezierPath, as implemnted, will yield the following error message on
archive/unarchive:
Exception: Uncaught exception NSInvalidArgumentException, reason:
-[NSKeyedArchiver encodeValueOfObjCType:at:]: this archiver cannot e encode
structs
Abort (core dumped)
Upon inspection of the source, I discovered @encode(NSBezierPathElement)
(which compiles to a struct) was used instead of @encode(enum
NSBezierPathElement) (enum is an Obj-C primitive) and made the corrections.
While I was there, I fixed the NSPoint elements to use the encode/decodePoint
as well. No doubt, these would have also caused the Exception to occur.
Tested very quickly. NSBezierPath can now be archived and unarchived.
_______________________________________________________
File Attachments:
-------------------------------------------------------
Date: Tuesday 11/27/2007 at 06:43 Name:
gnustep-gui-nsbezierpath-encode-fix.patch Size: 3kB By: wojno
<http://savannah.gnu.org/patch/download.php?file_id=14490>
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/patch/?6286>
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/
_______________________________________________
Bug-gnustep mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/bug-gnustep