Connecting Tech Pros Worldwide Forums | Help | Site Map

Memory Fault

Newbie
 
Join Date: Apr 2008
Posts: 3
#1: Apr 26 '08
Am getting an error Memory Fault(coreDump)
--------------------------------------------------------------------------------

Am getting the above mentioned error
MemoryFault(Coredump)while running an executable compiled with ProC

what shud i do?
and what can be the cause

arne's Avatar
Expert
 
Join Date: Oct 2006
Posts: 306
#2: Apr 27 '08

re: Memory Fault


Quote:

Originally Posted by Aptripathi

Am getting an error Memory Fault(coreDump)
--------------------------------------------------------------------------------

Am getting the above mentioned error
MemoryFault(Coredump)while running an executable compiled with ProC

what shud i do?
and what can be the cause

When producing a segfault you're typically accessing a memory region that you should not access, e.g. dereferencing a NULL pointer.

The core file that has been produced will give you a clue where the problem lies. (If you're using gcc use the '-g' option for producing debugging info; gdb -c <core file> <executable file> will then help you to identify the problem).

HTH,
arne
gpraghuram's Avatar
Expert
 
Join Date: Mar 2007
Location: Chennai
Posts: 1,258
#3: Apr 28 '08

re: Memory Fault


Quote:

Originally Posted by arne

When producing a segfault you're typically accessing a memory region that you should not access, e.g. dereferencing a NULL pointer.

The core file that has been produced will give you a clue where the problem lies. (If you're using gcc use the '-g' option for producing debugging info; gdb -c <core file> <executable file> will then help you to identify the problem).

HTH,
arne

As suggested by arne you can use gdb with core toidentify the problem.
after u have started the program with gdb and core type "where" which will give you the place where the program has crashed

Raghuram
Reply