Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Converting QD->CG



;-) Actually you almost had it. Start your application first 'cause I only know how to make gdb launch stuff with full path names and I don't like typing. =P

crazy8:~ ian$ gdb
GNU gdb 5.3-20030128 (Apple version gdb-330.1) (Fri Jul 16 21:42:28 GMT 2004)
Copyright 2003 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 MyApplication
Attaching to process 429.
0x900074c8 in mach_msg_trap ()
(gdb) break fprintf
Breakpoint 1 at 0x9000d3ac


and then just wait for fprintf() to get called which it should when something writes to stderr (the console log in normal situations). After that you should be able to get the stack trace with "backtrace" I think it is.

Ian


presume i'm a *total* newbie
i know nothing about the command line
i've never heard of gdb.

[nibiru:~] davec% gdb br fprintf
GNU gdb 5.3-20030128 (Apple version gdb-309) (Thu Dec 4 15:41:30 GMT 2003)
Copyright 2003 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".
br: No such file or directory.
/Users/davec/fprintf: No such file or directory.
(gdb)



On Nov 29, 2004, at 3:04 PM, Ian Anderson wrote:


On Nov 29, 2004, at 2:59 PM, David M. Cotter wrote:

--> "Ignoring Quickdraw drawing between QDBeginCGContext and QDEndCGContext"
is there a way to "set a breakpoint" on this somehow, so I can see the QD call that caused this??
Try setting a breakpoint at "fprintf" and look at the backtrace.

this must be obvious to everyone but me, but, ummm, I don't have the source code to "fprintf" in my project. i'm in CodeWarrior, how does one set a breakpoint on a line of code one does not have access to?

_______________________________________________ Do not post admin requests to the list. They will be ignored. Carbon-dev mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/carbon-dev/email@hidden

This email sent to email@hidden
References: 
 >Converting QD->CG (From: "David M. Cotter" <email@hidden>)
 >Re: Converting QD->CG (From: Joseph Maurer <email@hidden>)
 >Re: Converting QD->CG (From: "David M. Cotter" <email@hidden>)
 >Re: Converting QD->CG (From: Ian Anderson <email@hidden>)
 >Re: Converting QD->CG (From: "David M. Cotter" <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.