diff options
author | Daniel Black <daniel@mariadb.org> | 2022-09-19 10:37:26 +1000 |
---|---|---|
committer | Daniel Black <daniel@mariadb.org> | 2022-09-19 11:55:42 +1000 |
commit | 0f9e4029ea14ebb486c12f2b60c560e912f0beac (patch) | |
tree | 5f555457a5c172d021a131d111550feda718c10d | |
parent | 32bab2ce0518d829b4f97a272fc2431169744c75 (diff) | |
download | mariadb-git-bb-10.3-danielblack-MDEV-16194-pkgtest-remove-offset.tar.gz |
MDEV-16194 stack not resolve (addr2line)bb-10.3-danielblack-MDEV-16194-pkgtest-remove-offset
Remove the offset when invoking addr2line as tested by
Sergey Vojtovich.
-rw-r--r-- | mysys/my_addr_resolve.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/mysys/my_addr_resolve.c b/mysys/my_addr_resolve.c index f0c0d214171..a802cc41cb9 100644 --- a/mysys/my_addr_resolve.c +++ b/mysys/my_addr_resolve.c @@ -225,8 +225,6 @@ int my_addr_resolve(void *ptr, my_addr_loc *loc) int filename_start = -1; int line_number_start = -1; - void *offset; - poll_fds.fd = out[0]; poll_fds.events = POLLIN | POLLRDBAND; @@ -246,8 +244,7 @@ int my_addr_resolve(void *ptr, my_addr_loc *loc) /* Save result for future comparisons. */ strnmov(addr2line_binary, info.dli_fname, sizeof(addr2line_binary)); } - offset = info.dli_fbase; - len= my_snprintf(input, sizeof(input), "%08x\n", (ulonglong)(ptr - offset)); + len= my_snprintf(input, sizeof(input), "%p\n", ptr); if (write(in[1], input, len) <= 0) return 3; |