Horst Walter
Horst Walter

Reputation: 14081

Can I find the codeline causing the crash from this backtrace?

I have a backtrace like this, And I have the source code for xswiftbus. Is there a way to find out to which codeline the "numbers" belong?

So could I figure out my callstack from that. Either in QtC or VS2017.

I personally cannot reproduce the crash leading to this backtrace, but maybe I can at least see which functions are involved.

Backtrace is:
0 00007FF8EE00BE1B E:\X-Plane 11\Resources\plugins\xswiftbus\64\win.xpl+000000000000BE1B ()
1 00007FF8EE028D1D E:\X-Plane 11\Resources\plugins\xswiftbus\64\win.xpl+0000000000028D1D ()
2 00007FF8EE00A64D E:\X-Plane 11\Resources\plugins\xswiftbus\64\win.xpl+000000000000A64D ()
3 00007FF8EE028B19 E:\X-Plane 11\Resources\plugins\xswiftbus\64\win.xpl+0000000000028B19 ()
4 00007FF8EE00F025 E:\X-Plane 11\Resources\plugins\xswiftbus\64\win.xpl+000000000000F025 ()
5 00007FF9084E5202 E:\X-Plane 11\Resources\plugins\XPLM_64.dll+0000000000015202 ()
6 00007FF9084DB362 E:\X-Plane 11\Resources\plugins\XPLM_64.dll+000000000000B362 ()
7 00007FF7802156CA E:\X-Plane 11\X-Plane.exe+0000000000A456CA ()
8 00007FF77F8AA69E E:\X-Plane 11\X-Plane.exe+00000000000DA69E ()

Upvotes: 0

Views: 272

Answers (1)

Thomas Weller
Thomas Weller

Reputation: 59303

  1. Download and install WinDbg.

  2. Get the XPL file that matches the release (if possible, e.g. download that version) and rename it to DLL.

  3. Choose "Start debugging" and then "open dump file", even if you don't have a dump file.

  4. Select the renamed DLL file

  5. Type .symopt +40 in order to allow symbols to be loaded that do not match the binary.

  6. Type .symfix to get Microsoft symbols

  7. Type .sympath+ <path to your PDB>

  8. Type ln <address>

That should give an output like

0:000> ln 10009a9d
(10009a90)   MNbasic!str_encode_num_str+0xd   |  (10009b80)   MNbasic!str_alpha_num_code

So instead of just an offset, you now have a method name and an offset. If the offset is still very large, the symbols may be too far off.

Upvotes: 1

Related Questions