This is the mail archive of the
gdb@sources.redhat.com
mailing list for the GDB project.
Re: gdb signal normal termination of program
- From: Ruedi Dummermuth <ruedi at abatron dot ch>
- To: Shaun Jackman <sjackman at pathwayconnect dot com>
- Cc: bgat at billgatliff dot com,gdb at sources dot redhat dot com
- Date: Thu, 29 Nov 2001 08:41:58 +0100
- Subject: Re: gdb signal normal termination of program
Hello Shaun
The BDI cannot detect when you enter the exit() function
unless you set a breakpoint in it. The BDI cannot generate
the message "Program terminated normally" because
it has no information about when this event happens.
Also an embedded application normally does not terminate.
When you finally burn you application into flash, it should
run continuously and will never terminate via exit().
You may change your exit() function and code-in the opcode
of a software breakpoint. If you did not change it within the
BDI configuration, the opcode for a breakpoint is 0xE7FFDEFE.
Regards,
Ruedi
At 09:24 28.11.2001 -0700, you wrote:
>Hello,
>
>I have an arm-elf target connected to a bdi2000 jtag debugger. Is there any
>instruction I can compile that indicates to the debugger or gdb that
>my program has reached normal termination. When main returns exit() is called
>which then hangs the processor. I have to interrupt it with ctrl-c. I'd like
>gdb to break to the prompt on its own and display the message "Program
>terminated normally". Do you know how I go about this?
>
>Thanks,
>Shaun
==============================
Ruedi Dummermuth
Abatron AG
Lettenstrasse 9
CH-6343 Rotkreuz
Switzerland
mailto:ruedi@abatron.ch
http://www.abatron.ch
Tel ++41 41 792 09 55
Fax ++41 41 792 09 60