• 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
Re: [Q] Why unsolicited dealloc in NSKeyedUnarchiver?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Q] Why unsolicited dealloc in NSKeyedUnarchiver?


  • Subject: Re: [Q] Why unsolicited dealloc in NSKeyedUnarchiver?
  • From: "Louis C. Sacha" <email@hidden>
  • Date: Mon, 19 Apr 2004 22:57:11 -0700

Hello...

Actually, I don't think it is a problem with NSKeyedUnarchiver at all. You probably just need to retain the unarchived object in your loadDataRepresentation:ofType: method... (and check to make sure you release it in your document's dealloc method).

passwordRecords = [[NSKeyedUnarchiver unarchiveObjectWithData:data] retain];


Hope that helps,

Louis

In trying to add Open Recent support to MyDocument app everything is
working fine with the exception of an unsolicited call to dealloc by
NSKeyedUnarchiver. Any ideas where this is coming from and moreover
why? I'm confused. TIA for your help... Peter

From MyDocument
- (BOOL)loadDataRepresentation:(NSData *)data ofType:(NSString *)aType {
passwordRecords = [NSKeyedUnarchiver unarchiveObjectWithData:data];
return YES;
...
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.


  • Follow-Ups:
    • Re: [Q] Why unsolicited dealloc in NSKeyedUnarchiver?
      • From: "Peter.Teeson" <email@hidden>
References: 
 >[Q] Why unsolicited dealloc in NSKeyedUnarchiver? (From: "Peter.Teeson" <email@hidden>)

  • Prev by Date: How do I get the (int)Value of an NSStepperCell in an NSTableView?
  • Next by Date: Re: [Q] Why unsolicited dealloc in NSKeyedUnarchiver?
  • Previous by thread: [Q] Why unsolicited dealloc in NSKeyedUnarchiver?
  • Next by thread: Re: [Q] Why unsolicited dealloc in NSKeyedUnarchiver?
  • Index(es):
    • Date
    • Thread