diff mbox series

binutils replaces bfd_hostptr_t with uintptr_t

Message ID 20231130223115.107351-1-jaap.keuter@xs4all.nl
State Accepted
Headers show
Series binutils replaces bfd_hostptr_t with uintptr_t | expand

Commit Message

Jaap Keuter Nov. 30, 2023, 10:31 p.m. UTC
According to this message https://marc.info/?l=binutils&m=165363679302282
the type bfd_hostptr_t is dropped in favor of uintptr_t.
Replace the use of this type in the code.

Signed-off-by: Jaap Keuter <jaap.keuter@xs4all.nl>
---
 src/utils/trace.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

Comments

Jouni Malinen Dec. 2, 2023, 6:59 p.m. UTC | #1
On Thu, Nov 30, 2023 at 11:31:03PM +0100, Jaap Keuter wrote:
> According to this message https://marc.info/?l=binutils&m=165363679302282
> the type bfd_hostptr_t is dropped in favor of uintptr_t.
> Replace the use of this type in the code.

Thanks, applied.
diff mbox series

Patch

diff --git a/src/utils/trace.c b/src/utils/trace.c
index 8f12da87b..7c9a17ff8 100644
--- a/src/utils/trace.c
+++ b/src/utils/trace.c
@@ -197,7 +197,7 @@  static void wpa_trace_bfd_addr(void *pc)
 	if (abfd == NULL)
 		return;
 
-	data.pc = (bfd_hostptr_t) ((u8 *) pc - start_offset);
+	data.pc = (uintptr_t) ((u8 *) pc - start_offset);
 	data.found = FALSE;
 	bfd_map_over_sections(abfd, find_addr_sect, &data);
 
@@ -238,7 +238,7 @@  static const char * wpa_trace_bfd_addr2func(void *pc)
 	if (abfd == NULL)
 		return NULL;
 
-	data.pc = (bfd_hostptr_t) ((u8 *) pc - start_offset);
+	data.pc = (uintptr_t) ((u8 *) pc - start_offset);
 	data.found = FALSE;
 	bfd_map_over_sections(abfd, find_addr_sect, &data);
 
@@ -310,7 +310,7 @@  size_t wpa_trace_calling_func(const char *buf[], size_t len)
 	for (i = 0; i < btrace_num; i++) {
 		struct bfd_data data;
 
-		data.pc = (bfd_hostptr_t) ((u8 *) btrace_res[i] - start_offset);
+		data.pc = (uintptr_t) ((u8 *) btrace_res[i] - start_offset);
 		data.found = FALSE;
 		bfd_map_over_sections(abfd, find_addr_sect, &data);