mirror of
https://github.com/tobast/libunwind-eh_elf.git
synced 2025-01-11 19:43:42 +01:00
(TARGET_ELF64): Delete.
(TARGET_ELF32): Likewise. (_UPT_get_proc_name): Use ELF_CLASS instead of TARGET_ELFxx. (Logical change 1.130)
This commit is contained in:
parent
5e446b24d7
commit
7eaa3cea76
1 changed files with 4 additions and 11 deletions
|
@ -25,24 +25,17 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
|
||||||
|
|
||||||
#include "_UPT_internal.h"
|
#include "_UPT_internal.h"
|
||||||
|
|
||||||
#if defined(UNW_TARGET_IA64)
|
|
||||||
# define TARGET_ELF64
|
|
||||||
#elif defined(UNW_TARGET_X86)
|
|
||||||
# define TARGET_ELF32
|
|
||||||
#else
|
|
||||||
# warning Do not know object-file format of target arch. Please implement.
|
|
||||||
#endif
|
|
||||||
|
|
||||||
int
|
int
|
||||||
_UPT_get_proc_name (unw_addr_space_t as, unw_word_t ip,
|
_UPT_get_proc_name (unw_addr_space_t as, unw_word_t ip,
|
||||||
char *buf, size_t buf_len, unw_word_t *offp, void *arg)
|
char *buf, size_t buf_len, unw_word_t *offp, void *arg)
|
||||||
{
|
{
|
||||||
struct UPT_info *ui = arg;
|
struct UPT_info *ui = arg;
|
||||||
|
|
||||||
#if defined(TARGET_ELF64)
|
#if ELF_CLASS == ELFCLASS64
|
||||||
return _Uelf64_get_proc_name (ui->pid, ip, buf, buf_len, offp);
|
return _Uelf64_get_proc_name (ui->pid, ip, buf, buf_len, offp);
|
||||||
#elif defined(TARGET_ELF32)
|
#elif ELF_CLASS == ELFCLASS32
|
||||||
return _Uelf32_get_proc_name (ui->pid, ip, buf, buf_len, offp);
|
return _Uelf32_get_proc_name (ui->pid, ip, buf, buf_len, offp);
|
||||||
#endif
|
#else
|
||||||
return -UNW_ENOINFO;
|
return -UNW_ENOINFO;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue