• 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: file scan results in EX_BAD_ACCESS
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: file scan results in EX_BAD_ACCESS


  • Subject: Re: file scan results in EX_BAD_ACCESS
  • From: Fritz Anderson <email@hidden>
  • Date: Sat, 1 Sep 2007 10:19:51 -0500

And there it is. Calling [self release] in dealloc will result in an additional call to dealloc. Infinite loop.

Anyway
if (self)
[self release];
doesn't make sense. You don't get to dealloc unless the last release on self has already been encountered.


Also, unless you set self to nil in the method, if (self)... will always evaluate to true.

	— F


On Sep 1, 2007, at 10:10 AM, Daniel Child wrote:

- (void) dealloc
{
 [self setFieldDelim: nil];
 [self setRecordDelim: nil];
 if (self) [self release];
	[super dealloc];
}

_______________________________________________

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


  • Follow-Ups:
    • Re: file scan results in EX_BAD_ACCESS
      • From: Daniel Child <email@hidden>
References: 
 >Re: file scan results in EX_BAD_ACCESS (From: Daniel Child <email@hidden>)

  • Prev by Date: Re: NSBezierPath append CGGlyph
  • Next by Date: Re: file scan results in EX_BAD_ACCESS
  • Previous by thread: Re: file scan results in EX_BAD_ACCESS
  • Next by thread: Re: file scan results in EX_BAD_ACCESS
  • Index(es):
    • Date
    • Thread