Troubleshooting crashes: Difference between revisions

Jump to navigation Jump to search
m
→‎Debugging Segfaults & Obtaining Backtraces: http://forum.flightgear.org/viewtopic.php?f=17&t=19670&hilit=backtrace+cxx&start=15#p181541
(→‎Debugging Segfaults & Obtaining Backtraces: http://forum.flightgear.org/viewtopic.php?f=17&t=19670&p=181541&hilit=backtrace+cxx#p181541)
m (→‎Debugging Segfaults & Obtaining Backtraces: http://forum.flightgear.org/viewtopic.php?f=17&t=19670&hilit=backtrace+cxx&start=15#p181541)
Line 162: Line 162:


A '''segfault''' is another word for "crash", it's a so called "segmentation fault", where the program is doing things that it wasn't designed to do, such as accessing invalid memory for example, so that the operating system will terminate the process because its behavior is no longer valid/correct. These '''segfaults''' will typically happen due to coding errors, either in FlightGear or one of its dependencies (libraries like SimGear, plib, OpenSceneGraph or OpenAL).  
A '''segfault''' is another word for "crash", it's a so called "segmentation fault", where the program is doing things that it wasn't designed to do, such as accessing invalid memory for example, so that the operating system will terminate the process because its behavior is no longer valid/correct. These '''segfaults''' will typically happen due to coding errors, either in FlightGear or one of its dependencies (libraries like SimGear, plib, OpenSceneGraph or OpenAL).  
A typical segfault may look like this:
<syntaxhighlight lang="text">
Initializing splash screen
Splash screen progress init
Tungsten Graphics, Inc.
Mesa DRI R200 (RV250 4C66) x86/MMX/SSE2 TCL DRI2
1.3 Mesa 9.1.1
Program received signal SIGSEGV, Segmentation fault.
0xb71467e6 in __strlen_sse2_bsf () from /usr/lib/libc.so.6
</syntaxhighlight>
The last two lines are basically showing the actual crash, anything shown earlier is normally just an indicator how far the code could proceed shortly before the crash actually occurred. 


In order to see what was going on when the crash occurred, you'll need to build a binary with '''debugging symbols''' enabled/included, usually this includes FlightGear and SimGear - and possibly even OSG (OpenSceneGraph, normally only if your crash happens inside rendering related code).
In order to see what was going on when the crash occurred, you'll need to build a binary with '''debugging symbols''' enabled/included, usually this includes FlightGear and SimGear - and possibly even OSG (OpenSceneGraph, normally only if your crash happens inside rendering related code).

Navigation menu