summaryrefslogtreecommitdiff
path: root/libbacktrace/backtrace.h
diff options
context:
space:
mode:
authorIan Lance Taylor <iant@golang.org>2021-03-02 13:45:56 -0800
committerIan Lance Taylor <iant@golang.org>2021-03-02 13:46:48 -0800
commitdf003d1e0bf2d0a8e2ed45a323d4e974b15dc95f (patch)
tree43c1f8e66ad1ce5f903ec9b471f7f529f2f2c8f4 /libbacktrace/backtrace.h
parent41fbacdd10305654b1d10f887fa3f4677f9b8f34 (diff)
libbacktrace: pass -1 to error callback for unrecognized DWARF
PR libbacktrace/98818 * dwarf.c (dwarf_buf_error): Add errnum parameter. Change all callers. * backtrace.h: Update backtrace_error_callback comment.
Diffstat (limited to 'libbacktrace/backtrace.h')
-rw-r--r--libbacktrace/backtrace.h15
1 files changed, 8 insertions, 7 deletions
diff --git a/libbacktrace/backtrace.h b/libbacktrace/backtrace.h
index 2814763f417..caaa66d3686 100644
--- a/libbacktrace/backtrace.h
+++ b/libbacktrace/backtrace.h
@@ -71,13 +71,14 @@ struct backtrace_state;
invalid after this function returns.
As a special case, the ERRNUM argument will be passed as -1 if no
- debug info can be found for the executable, but the function
- requires debug info (e.g., backtrace_full, backtrace_pcinfo). The
- MSG in this case will be something along the lines of "no debug
- info". Similarly, ERRNUM will be passed as -1 if there is no
- symbol table, but the function requires a symbol table (e.g.,
- backtrace_syminfo). This may be used as a signal that some other
- approach should be tried. */
+ debug info can be found for the executable, or if the debug info
+ exists but has an unsupported version, but the function requires
+ debug info (e.g., backtrace_full, backtrace_pcinfo). The MSG in
+ this case will be something along the lines of "no debug info".
+ Similarly, ERRNUM will be passed as -1 if there is no symbol table,
+ but the function requires a symbol table (e.g., backtrace_syminfo).
+ This may be used as a signal that some other approach should be
+ tried. */
typedef void (*backtrace_error_callback) (void *data, const char *msg,
int errnum);