Re: [AD] Patch for fixing missing NSAutoreleasePools

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


On 2012-05-26, at 12:24 AM, Evert Glebbeek wrote:
> I can't say either way without more context/looking into it. Agree it looks a bit odd though.

Reading up about it here: http://cocoadev.com/wiki/AutoRelease

Leads me to believe that it should be return [img autorelease];

Basically sending autorelease to an object makes it "self destruct" on the local autorelease pool ends. The image returned is used by some objc methods but those should retain it if the need to, and running ex_icon, it seems to work fine. I'll commit it that way for now, it can be changed if somebody knows better than me.

Trent



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/