• 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: Passing param by reference then using within block throws exception
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Passing param by reference then using within block throws exception


  • Subject: Re: Passing param by reference then using within block throws exception
  • From: Jens Alfke <email@hidden>
  • Date: Tue, 20 Sep 2016 23:29:37 -0700

I think the real problem is that the -enumerateObjectsUsingBlock: method has an autorelease pool. If your real code is assigning something other than a string constant to *fillMeIn, that string will probably get dealloced when the autorelease pool drains. Your workaround is correct, since assigning the string to noFillMeIn causes it to be retained.

—Jens
_______________________________________________

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: Passing param by reference then using within block throws exception
      • From: Steve Mills <email@hidden>
References: 
 > Passing param by reference then using within block throws exception (From: Steve Mills <email@hidden>)

  • Prev by Date: Re: NSMenuItem’s userKeyEquivalent lost if changing title
  • Next by Date: Re: How to Launch an App using the Bundle ID?
  • Previous by thread: Re: Passing param by reference then using within block throws exception
  • Next by thread: Re: Passing param by reference then using within block throws exception
  • Index(es):
    • Date
    • Thread