Backtrace library.
More...
Backtrace library.
◆ BT_PRI_ADDRESS
| #define BT_PRI_ADDRESS PRIuLEAST64 |
format specifier for bt_address_t
Definition at line 29 of file backtrace.h.
◆ bt_address_t
an address of a symbol
Definition at line 26 of file backtrace.h.
◆ bt_error_begin_t
| typedef void(* bt_error_begin_t) (size_t error, void *user) |
called once when a system error occurs
- Parameters
-
| error | the error to report |
| user | the user data |
Definition at line 80 of file backtrace.h.
◆ bt_error_end_t
| typedef void(* bt_error_end_t) (void *user) |
called once when a system error occurs
- Parameters
-
Definition at line 85 of file backtrace.h.
◆ bt_trace_t
user callback for bt_read
- Parameters
-
| frame | the frame to resolve |
| user | user data |
Definition at line 74 of file backtrace.h.
◆ bt_resolve_t
how much of a frame was reconstructed
| Enumerator |
|---|
| eResolveNothing | nothing was resolved
|
| eResolveLine | the line number was found
- Note
- this does not imply eResolveFile
|
| eResolveName | the symbol name was found
- Note
- this does not imply eResolveDemangledName
|
| eResolveDemangledName | the symbol name was demangled
|
| eResolveFile | the file path was found
- Note
- this does not imply eResolveLine
|
| eResolveAll | all information was resolved
|
Definition at line 46 of file backtrace.h.
◆ bt_backend()
get the backtrace backend name
- Returns
- the backtrace backend name
Definition at line 17 of file dbghelp.c.
◆ bt_init()
| CT_BACKTRACE_API void bt_init |
( |
void |
| ) |
|
initialize the backtrace backend
- Note
- this function must be called before any other backtrace function
Definition at line 139 of file dbghelp.c.
◆ bt_read()
| CT_BACKTRACE_API void bt_read |
( |
bt_trace_t |
callback, |
|
|
void * |
user |
|
) |
| |
get a backtrace from the current location using a callback
- Note
- this function is not thread safe
- Precondition
- bt_init must be called before calling this function
- Parameters
-
| callback | the callback to call for each frame |
| user | the user data to pass to the callback |
Definition at line 35 of file common.c.
◆ bt_resolve_symbol()
resolve a frame to a symbol
- Precondition
- bt_init must be called before calling this function
- Parameters
-
| frame | the frame to resolve |
| symbol | the symbol to fill |
Definition at line 14 of file common.c.
◆ bt_update()
| CT_BACKTRACE_API void bt_update |
( |
void |
| ) |
|
update the loaded module cache
- Warning
- this function is not thread safe
- Note
- this function should be called after loading a shared library
Definition at line 147 of file dbghelp.c.
◆ gSystemError
the global system error handler
Definition at line 11 of file common.c.