Re: Gcc and Core dump
Sam wrote:
> Hi all
>
> I am a C++ programmer, and very new in Linux and using gcc. When I am
> compiling my program, I am getting error and core dump. I was wondering if
> there is any flag or some way in gcc that make it possible too see what the
> error is, and where it is located. or some more information about the error.
If you compile your code with the -g option (for debug), you can run the
program in a debugger (like ddd for example) and will show you where the
problem is. Alternatively, you can load the program into a debugger with
the core file and find out the state of the program at the point of failure.
Pual
|