• 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: Over-released Paragraph Style - Driving Me NUTS!
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Over-released Paragraph Style - Driving Me NUTS!


  • Subject: Re: Over-released Paragraph Style - Driving Me NUTS!
  • From: Seth Willits <email@hidden>
  • Date: Fri, 20 Oct 2006 15:40:39 -0700

On Oct 20, 2006, at 2:35 PM, j o a r wrote:

The only thing is that it didn't help me at all. There are three events for the object, the alloc, the autorelease, and the free. The alloc is from the buildParagraphStyle method, the autorelease is from the same, and the release is from the autorelease pool. Despite checking the box to manage retain and release calls, they were not, so I have no more information than when I started. Am I missing something?

How sure are you that it's actually ever being retained?

100% considering it's being put into a dictionary and dictionaries retain objects and that's the only location it's being released from.



Can you add debug print statements to your code, that includes the pointer address of your objects, to be 100% sure that the over- released object has actually passed through a code path where it's retained?


There's no question that it's not being retained. I can show you the hundreds of thousands of retain messages, but it's also clearly *must* happen:


- (void)setDefaultParagraph:(NSParagraphStyle *)paragraph { [paragraph retain]; [defaultParagraph release]; defaultParagraph = paragraph; }


- (NSParagraphStyle *)buildParagraphStyle:(NSFont *)font;
{
NSMutableParagraphStyle * ps = [[[NSMutableParagraphStyle alloc] init] autorelease];
...
return ps;
}



And defaultParagraph is what's being killed.



--
Seth Willits



_______________________________________________
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: Over-released Paragraph Style - Driving Me NUTS!
      • From: Kay Roepke <email@hidden>
References: 
 >Over-released Paragraph Style - Driving Me NUTS! (From: Seth Willits <email@hidden>)
 >Re: Over-released Paragraph Style - Driving Me NUTS! (From: j o a r <email@hidden>)
 >Re: Over-released Paragraph Style - Driving Me NUTS! (From: Seth Willits <email@hidden>)
 >Re: Over-released Paragraph Style - Driving Me NUTS! (From: j o a r <email@hidden>)
 >Re: Over-released Paragraph Style - Driving Me NUTS! (From: Seth Willits <email@hidden>)
 >Re: Over-released Paragraph Style - Driving Me NUTS! (From: j o a r <email@hidden>)

  • Prev by Date: How to limit expansion in NSOutlineView
  • Next by Date: Dragging files and folders into NSView subclasses
  • Previous by thread: Re: Over-released Paragraph Style - Driving Me NUTS!
  • Next by thread: Re: Over-released Paragraph Style - Driving Me NUTS!
  • Index(es):
    • Date
    • Thread