• 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: set a breakpoint in szone_error to debug
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: set a breakpoint in szone_error to debug


  • Subject: Re: set a breakpoint in szone_error to debug
  • From: Jim Ingham <email@hidden>
  • Date: Wed, 12 Oct 2005 08:55:28 -0700

I looks like not all the malloc errors go through szone_error. Somebody ought to fix that error message. Anyway, they do all go through "malloc_printf". Try breaking there.

Jim

On Oct 12, 2005, at 7:39 AM, Sean McBride wrote:

On 2005-09-26 21:51, Chris Espinosa said:


On Sep 26, 2005, at 9:35 PM, Tor Langballe wrote:


I can't for the life on me find any information on where/how to find
"szone_error" to put  a breakpoint there.


In the Xcode user interface (2.1 or later): - open the Breakpoints window - look for the blue cube labeled "Double-click to enter a symbolic breakpoint" - double-click it - enter 'szone_error'

Or from the gdb console:
- b szone_error
- c


Chris,

I've just now been trying to do this, but it doesn't work, or I need
coffee, or something...

First of all, I have 'fb szone_error' in my .gdbinit file.  Next, I
launch my app in the xCode debugger, hit my splash screen, hit pause,
and type:

(gdb) info b
Num Type           Disp Enb Address    What
1   breakpoint     keep y   0x9289dd68 <-[NSException raise]>
2   breakpoint     keep y   0x92950b74 <-[_NSZombie release]>
3   breakpoint     keep y   <PENDING>  szone_error

hmmm, .gdbinit worked for 2 of 3... why is szone_error pending? Anyway, then:

(gdb) b szone_error
Breakpoint 4 at 0x9010d144
(gdb) info b
Num Type           Disp Enb Address    What
1   breakpoint     keep y   0x9289dd68 <-[NSException raise]>
2   breakpoint     keep y   0x92950b74 <-[_NSZombie release]>
3   breakpoint     keep y   <PENDING>  szone_error
4   breakpoint     keep y   0x9010d144 <szone_error+36>
(gdb) c
Continuing.
Pending breakpoint 3 - "szone_error" resolved

OK, looks like I should have 2 breakpoints there!  Now repro a bug...

Brainsight(29735,0xa000ef98) malloc: *** Deallocation of a pointer not
malloced: 0xf252a0; This could be a double free(), or free() called with
the middle of an allocated block; Try setting environment variable
MallocHelp to see tools to help debug
Brainsight(29735,0xa000ef98) malloc: *** error for object 0xf25730: Non-
aligned pointer being freed (2)
Brainsight(29735,0xa000ef98) malloc: *** set a breakpoint in szone_error
to debug
Brainsight(29735,0xa000ef98) malloc: *** error for object 0xf25770: Non-
aligned pointer being freed (2)
Brainsight(29735,0xa000ef98) malloc: *** set a breakpoint in szone_error
to debug


etc. etc. ad nauseum,

But it never breaks!  Am I doing something wrong?

Thanks!

--
____________________________________________________________
Sean McBride, B. Eng                 email@hidden
Rogue Research                        www.rogue-research.com
Mac Software Developer              Montréal, Québec, Canada


_______________________________________________ Do not post admin requests to the list. They will be ignored. Xcode-users mailing list (email@hidden) Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


_______________________________________________ Do not post admin requests to the list. They will be ignored. Xcode-users mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
  • Follow-Ups:
    • Re: set a breakpoint in szone_error to debug
      • From: "Sean McBride" <email@hidden>
References: 
 >Re: set a breakpoint in szone_error to debug (From: "Sean McBride" <email@hidden>)

  • Prev by Date: Re: Incompatibilities between home-compiled and apple's libpng
  • Next by Date: type/value mismatch error in template
  • Previous by thread: Re: set a breakpoint in szone_error to debug
  • Next by thread: Re: set a breakpoint in szone_error to debug
  • Index(es):
    • Date
    • Thread