Re: Debuging
Re: Debuging
- Subject: Re: Debuging
- From: Andrew Farmer <email@hidden>
- Date: Tue, 16 Jan 2007 09:18:58 -0800
On 16 Jan 07, at 09:02, I. Savant wrote:
On Jan 16, 2007, at 11:46 AM, Olariu Adrian Mihai wrote:
I'm currently developing a bundle(for itunes) and I want to
debug it using breakpoints. Is this possible? How?
Both of these questions can be answered by reading your XCode user
manual.
Actually, not. iTunes uses PT_DENY_ATTACH, so the answer is actually
"you can't". Debugging your bundle will be rather difficult.
ptrace(2) says: "PT_DENY_ATTACH: This request [...] allows a process
that is not currently being traced to deny future traces by its
parent. [...] An attempt by the parent to trace a process which has
set this flag will result in a segmentation violation in the parent."
And indeed:
% ps x|grep iTunes
396 ?? S 7:26.64 /Applications/iTunes.app/Contents/MacOS/
iTunes -psn_0
% gdb
GNU gdb 6.3.50-20050815 (Apple version gdb-563) (Wed Jul 19 05:17:43
GMT 2006)
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and
you are
welcome to change it and/or distribute copies of it under certain
conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for
details.
This GDB was configured as "powerpc-apple-darwin".
(gdb) attach 396
Attaching to process 396.
zsh: segmentation fault gdb
%
_______________________________________________
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
References: | |
| >Debuging (From: Olariu Adrian Mihai <email@hidden>) |
| >Re: Debuging (From: "I. Savant" <email@hidden>) |