This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Re: WeirdProcess runs in GDB but not natively
- From: Jim Blandy <jimb at codesourcery dot com>
- To: grinthock <grinthock at gmail dot com>
- Cc: gdb at sources dot redhat dot com
- Date: Tue, 24 Oct 2006 09:55:34 -0700
- Subject: Re: WeirdProcess runs in GDB but not natively
- References: <6965889.post@talk.nabble.com>
grinthock <grinthock@gmail.com> writes:
> Unsure if this is the perfect place to post this, if you know another
> appropriate place please advise.
>
> I have a compiled app, when I attempt to run it with ./appname it fails with
> an "ABORT TRAP" and i'm unsure of why.
>
> Someone suggested GDB, so I of course ran it with GDB ./process and then
> RUN and the program runs.
>
> So why would a program run in GDB, but not natively? What's different?
>
> Thanks. (FYI, it's a Darwin on a PPC G5 PowerMAC)
Generally GDB tries to disturb the program as little as possible.
Ideally programs would always behave exactly the same way under GDB
that they do otherwise.
I couldn't say from what you've written here what's going on. I'm the
opposite of a Darwin expert, though. Maybe the program is
multi-threaded, and has a race condition, and its timing is being
affected by GDB.
If you have a program you can post that we could try out ourselves,
that would be the most helpful thing.