• 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: Memory management in QuickLook plugin
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Memory management in QuickLook plugin


  • Subject: Re: Memory management in QuickLook plugin
  • From: Corbin Dunn <email@hidden>
  • Date: Wed, 20 May 2009 11:00:06 -0700


On May 20, 2009, at 6:34 AM, Georg Seifert wrote:


Hi,



I’m developing a QuickLook plugin for a custom binary file format.



As long as I did not cared about memory leaks everything was fine. Then I fixed the leak with the help of Instruments. Everything runs fine from xCode and Instruments but now it crashes if I run the plugin from the finder.





Do you mean quicklookd crashes but qlmanage does not?

Yes.




I have set up a custom executable with "/usr/bin/qlmanage" and the argument "-p path/to/my/file".



Any advice is very welcome.



We lack information here. We'd need to know where it is crashing.


This is definitely a memory problem. Sometimes it is about memory being double released and sometimes things like:
20.05.09 13:42:00 quicklookd[38490] [QL ERROR] Preview request generator for <QLPreviewRequest /Users/georg/...> raised '*** - [NSCFString saveGraphicsState]: unrecognized selector sent to instance 0x138880'


the only call to saveGraphicsState is: [NSGraphicsContext saveGraphicsState];

So this seem exactly what happends with wrong retain/releases. The Problem is, I cannot debug it because in the debugger everything is fine.

Use Zombies and Instruments.

http://www.corbinstreehouse.com/blog/index.php/2007/10/instruments-on-leopard-how-to-debug-those-random-crashes-in-your-cocoa-app/

corbin


_______________________________________________

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: 
 >Memory management in QuickLook plugin (From: Georg Seifert <email@hidden>)
 >Re: Memory management in QuickLook plugin (From: Julien Jalon <email@hidden>)
 >Re: Memory management in QuickLook plugin (From: Georg Seifert <email@hidden>)

  • Prev by Date: Re: using fileWrapperFromRange: for lossy conversion
  • Next by Date: RE: [OT] Anyone have the a DIRECT phone number for a real person at Apple Legal???
  • Previous by thread: Re: Memory management in QuickLook plugin
  • Next by thread: Fwd: Memory management in QuickLook plugin
  • Index(es):
    • Date
    • Thread