BUILD: tools: make resolve_sym_name() return a const

Originally it was made to return a void* because some comparisons in the
code where it was used required a lot of casts. But now we don't need
that anymore. And having it non-const breaks the build on NetBSD 9 as
reported in issue #728.

So let's switch to const and adjust debug.c to accomodate this.
This commit is contained in:
Willy Tarreau
2020-07-05 20:26:04 +02:00
parent 4c442b08b3
commit 0c439d8956
3 changed files with 3 additions and 3 deletions

View File

@@ -996,7 +996,7 @@ int dump_text_line(struct buffer *out, const char *buf, int bsize, int len,
void dump_addr_and_bytes(struct buffer *buf, const char *pfx, const void *addr, int n);
void dump_hex(struct buffer *out, const char *pfx, const void *buf, int len, int unsafe);
int may_access(const void *ptr);
void *resolve_sym_name(struct buffer *buf, const char *pfx, void *addr);
const void *resolve_sym_name(struct buffer *buf, const char *pfx, void *addr);
const char *get_exec_path();
#if defined(USE_BACKTRACE)