This is the mail archive of the gdb@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Using gdb to debug Segmentation fault on linux


Hello Ying,

On Tue, Oct 02, 2007 at 06:46:22PM -0500, ying lcs wrote:
> Program received signal SIGSEGV, Segmentation fault.
> [Switching to Thread -1218548816 (LWP 25361)]
> 0x08067623 in RTPStream::SendRTCPSR (this=0x83a1520, inTime=@0x1b9a5b58,
>     inAppendBye=0) at RTCPUtilitiesLib/RTCPSRPacket.h:123
> 123         ((UInt32*)&fSenderReportBuffer)[(fSenderReportWithServerInfoSize
> >> 2) + 1] = htonl(inSSRC);

First, you need to understand what SIGSEGV is. See, e.g.,
http://en.wikipedia.org/wiki/SIGSEGV .

Second, you need to understand what exactly caused it. "p
&((UInt32*)&fSenderReportBuffer)[(fSenderReportWithServerInfoSize >> 2)
+ 1]" at the gdb prompt might give a hint (compare it with the value of
fSenderReportBuffer and sizeof fSenderReportBuffer).

Only when these two are clear it would make sense to look at the bt,
which may or may not help.

With kind regards,
-- 
Baurzhan Ismagulov
http://www.kz-easy.com/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]