• 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: NSBezierPath EXC_BAD_ACCESS issues.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSBezierPath EXC_BAD_ACCESS issues.


  • Subject: Re: NSBezierPath EXC_BAD_ACCESS issues.
  • From: Graham Cox <email@hidden>
  • Date: Thu, 4 Mar 2010 00:22:28 +1100

On 04/03/2010, at 12:14 AM, Billy Flatman wrote:

> I'm new to Objective-C as you've probably gathered and am not 100% about how the memory management works. Will I be causing a memory leek with the line:
> path = [[NSBezierPath alloc] bezierPath];
> within my initialiseBezierPath method?
>


Well, it won't work because -bezierPath isn't an instance method of NSBezierPath, it's a class method.

Take a step back, read this. And then again. Until it clicks.

http://developer.apple.com/mac/library/documentation/Cocoa/Conceptual/MemoryMgmt/Articles/mmRules.html

--Graham


_______________________________________________

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

References: 
 >NSBezierPath EXC_BAD_ACCESS issues. (From: Billy Flatman <email@hidden>)
 >Re: NSBezierPath EXC_BAD_ACCESS issues. (From: Graham Cox <email@hidden>)
 >Re: NSBezierPath EXC_BAD_ACCESS issues. (From: Billy Flatman <email@hidden>)

  • Prev by Date: Re: NSBezierPath EXC_BAD_ACCESS issues.
  • Next by Date: Re: How a window was closed?
  • Previous by thread: Re: NSBezierPath EXC_BAD_ACCESS issues.
  • Next by thread: Help Book Icon in Xcode 3.2
  • Index(es):
    • Date
    • Thread