Re: Printing crash
Re: Printing crash
- Subject: Re: Printing crash
- From: "Jeff Hellman" <email@hidden>
- Date: Sat, 17 Feb 2007 21:22:24 -0800
So, I've spent more time looking into this problem and have made very
little progress. I can make my app crash at will by loading the
PrintingCocoaPDEs.bundle at any time (awakeFromNib in MyDocument.m,
for example). Loading other bundles (PrintCocoaUI.bundle, for
example) works fine.
I get no Zombie or other information with NSZombieEnabled or MallocStackLogging
I can make my app work perfectly by enabling ZeroLink but this isn't
an option for a non-development release
I've run my app through nm and compared the symbol table to that of
the PrintingCocoaPDEs and found nothing out of the ordinary (though,
I'm a little confused by what I'd be looking for). What I did was
compare the similar entries in the nm for my app and PrintingCocoaPDEs
and PrintCocoaUI (which loads fine). I noticed noticed no substantial
differences between the similarities in PrintingCocoaPDEs and my app
and PrintCocoaUI and my app....
Here's the debugger information that's shown when my app crashes (upon
loading PrintingCocoaPDEs in awakeFromNib:)
#0 0x90a58b58 in _cache_flush
#1 0x90a58991 in flush_caches
#2 0x90a5dc10 in _objc_read_categories_from_image
#3 0x90a53b4b in _objc_notify_images
#4 0x8fe0e3c8 in
__dyld__ZN16ImageLoaderMachO14doNotificationE15dyld_image_modejPK15dyld_image_info
#5 0x8fe05255 in __dyld__ZN4dyld12notifyAddingERSt6vectorIP11ImageLoaderSaIS2_EE
#6 0x8fe0cbcd in
__dyld__ZN11ImageLoader4linkERKNS_11LinkContextENS_15BindingLazinessENS_18InitializerRunningEj
#7 0x8fe03982 in
__dyld__ZN4dyld4linkEP11ImageLoaderNS0_15BindingLazinessENS0_18InitializerRunningE
#8 0x8fe08721 in __dyld_NSLinkModule
#9 0x0102f525 in NSLinkModule at mach_portUser.c:2078
#10 0x90a57cd4 in objc_loadModule
#11 0x9260007f in _NSBundleLoadCode
#12 0x925ff957 in -[NSBundle load]
#13 0x000406ff in -[MyDocument awakeFromNib]
I'm totally out of ideas here and would really like to get this solved
so I don't have to resort to [NSPrintOperation setShowsPanel:NO] to
enable printing in my application. Any thoughts?
Thanks again-
Jeff
On 2/13/07, Daniel Jalkut <email@hidden> wrote:
Do they also happen when simply trying to load the affected plugin? I think
you should focus on that instead of printing, because it's a simpler test
case. In fact, I'd test loading that bundle manually as early as possible
in your app, to see if there's a point at which loading it is safe.
I don't agree with the theory that EXC_BAD_ACCESS is a "clear indication
that you have a memory management problem." Lots of things could be going
wrong here, and to me it sounds like you're chasing red herring.
You've got a simple crashing test case in 2 lines of code, now it's just
down to figuring out when and why those 2 lines of code will cause a crash.
Daniel
On Feb 13, 2007, at 2:41 AM, Jeff Hellman wrote:
Ok...so when I got this all working, I think, I wind up with these two
outputs to the run log when trying to print:
--
Jeff Hellman
email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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