debugging - Help for gdb debug crash logging -


i have been debugging in gdb (c code). issue if run application , if crashes, control comes main()(app restarts). hence have no idea crashed. spend lot of time stepping through each function.

i know if there anyway log can enabled generate last line of execution before crash. assumption, if there other simpler way of doing please let me know, save great deal of time me!

also if gdb generates log path be?

thanks in advance.

this question little unclear me, i'll take stab:

if have gdb attached crashing process when crashes, crash should stop program , put @ (gdb) prompt. if type bt, should see stack.

if not have gdb attached, this answer related question might help. (in short, maybe want system create core dump when program crashes. core dump file contains lot of information crashed process. can use gdb core dump see stack.)

if don't know, post see on screen when happens, , we'll guess.

in case, program should not start on @ main(). seems worthwhile track down why happens , precisely what's going on. control jump main in same process, opposed process somehow being automatically started?


Comments

Popular posts from this blog

asp.net - repeatedly call AddImageUrl(url) to assemble pdf document -

java - Android recognize cell phone with keyboard or not? -

iphone - How would you achieve a LED Scrolling effect? -