• 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: Unarchiver problems!
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Unarchiver problems!


  • Subject: Re: Unarchiver problems!
  • From: glenn andreas <email@hidden>
  • Date: Fri, 25 Mar 2005 23:41:30 -0600


On Mar 25, 2005, at 11:29 PM, Tom Birch wrote:

This is following on from my "Bindings problems" thread, I have reduced the problem down to something with NSUnarchiver, or, something. Here is a gdb trace that should give you a fair idea of what is going on:

http://tbir905.web.cse.unsw.edu.au/gdbsession.txt


38 - (id)initWithCoder:(NSCoder *)coder 39 { 40 if(self = [super init]) 41 { 42 dict = [coder decodeObject]; 43 } 44 return self;


Line 42 should be dict = [[coder decodeObject] retain];

since otherwise the value returned from decodeObject is autoreleased so it will go away "real soon" (and obviously you want to keep it around, instead of having it replaced with random flotsam).


Glenn Andreas                      email@hidden  <http://www.gandreas.com/> oh my! Mad, Bad, and Dangerous to Know

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Unarchiver problems!
      • From: Ricky Sharp <email@hidden>
    • Re: Unarchiver problems!
      • From: Tom Birch <email@hidden>
References: 
 >Unarchiver problems! (From: Tom Birch <email@hidden>)

  • Prev by Date: Unarchiver problems!
  • Next by Date: Re: Unarchiver problems!
  • Previous by thread: Unarchiver problems!
  • Next by thread: Re: Unarchiver problems!
  • Index(es):
    • Date
    • Thread