From b713edb9a7f3da8e4dd28ac69a1665ed493ca504 Mon Sep 17 00:00:00 2001 From: Andreas Schwab Date: Wed, 10 Aug 2022 10:52:42 +0200 Subject: [PATCH] readelf: Handle SHT_RISCV_ATTRIBUTES like SHT_GNU_ATTRIBUTES Signed-off-by: Andreas Schwab --- src/readelf.c | 4 +++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/readelf.c b/src/readelf.c index f1f77ce81..1a10fd01e 100644 --- a/src/readelf.c +++ b/src/readelf.c @@ -3672,7 +3672,9 @@ print_attributes (Ebl *ebl, const GElf_Ehdr *ehdr) && (shdr->sh_type != SHT_ARM_ATTRIBUTES || ehdr->e_machine != EM_ARM) && (shdr->sh_type != SHT_CSKY_ATTRIBUTES - || ehdr->e_machine != EM_CSKY))) + || ehdr->e_machine != EM_CSKY) + && (shdr->sh_type != SHT_RISCV_ATTRIBUTES + || ehdr->e_machine != EM_RISCV))) continue; printf (_("\ -- 2.31.1